diff --git a/tests/key-locator.cpp b/tests/key-locator.cpp
new file mode 100644
index 0000000..00f4ff9
--- /dev/null
+++ b/tests/key-locator.cpp
@@ -0,0 +1,39 @@
+/**
+ * Copyright (C) 2013 Regents of the University of California.
+ * See COPYING for copyright and distribution information.
+ */
+
+#include "key-locator.hpp"
+
+#include <boost/test/unit_test.hpp>
+#include <boost/concept_check.hpp>
+
+namespace ndn {
+
+BOOST_AUTO_TEST_SUITE(TestKeyLocator)
+
+BOOST_AUTO_TEST_CASE(Equality)
+{
+  BOOST_CONCEPT_ASSERT((boost::EqualityComparable<KeyLocator>));
+
+  KeyLocator a;
+  KeyLocator b;
+  BOOST_CHECK_EQUAL(a == b, true);
+  BOOST_CHECK_EQUAL(a != b, false);
+
+  a.setName("ndn:/A");
+  BOOST_CHECK_EQUAL(a == b, false);
+  BOOST_CHECK_EQUAL(a != b, true);
+
+  b.setName("ndn:/B");
+  BOOST_CHECK_EQUAL(a == b, false);
+  BOOST_CHECK_EQUAL(a != b, true);
+
+  b.setName("ndn:/A");
+  BOOST_CHECK_EQUAL(a == b, true);
+  BOOST_CHECK_EQUAL(a != b, false);
+}
+
+BOOST_AUTO_TEST_SUITE_END()
+
+} // namespace ndn
diff --git a/tests/test-block.cpp b/tests/test-block.cpp
index 32cd8cd..1c7557d 100644
--- a/tests/test-block.cpp
+++ b/tests/test-block.cpp
@@ -3,10 +3,11 @@
  * See COPYING for copyright and distribution information.
  */
 
-#include <boost/test/unit_test.hpp>
-
 #include "encoding/encoding-buffer.hpp"
 
+#include <boost/test/unit_test.hpp>
+#include <boost/concept_check.hpp>
+
 using namespace std;
 namespace ndn {
 
@@ -563,6 +564,26 @@
   BOOST_CHECK_THROW(testBlock = Block(stream), Tlv::Error);
 }
 
+BOOST_AUTO_TEST_CASE(Equality)
+{
+  BOOST_CONCEPT_ASSERT((boost::EqualityComparable<Block>));
+
+  Block a("\x08\x00", 2);
+  Block b("\x08\x00", 2);;
+  BOOST_CHECK_EQUAL(a == b, true);
+  BOOST_CHECK_EQUAL(a != b, false);
+
+  Block c("\x06\x00", 2);
+  Block d("\x08\x00", 2);;
+  BOOST_CHECK_EQUAL(c == d, false);
+  BOOST_CHECK_EQUAL(c != d, true);
+
+  Block e("\x06\x00", 2);
+  Block f("\x06\x01\xcc", 3);;
+  BOOST_CHECK_EQUAL(e == f, false);
+  BOOST_CHECK_EQUAL(e != f, true);
+}
+
 BOOST_AUTO_TEST_SUITE_END()
 
 } // namespace ndn
diff --git a/tests/test-interest.cpp b/tests/test-interest.cpp
index 2583f98..321685e 100644
--- a/tests/test-interest.cpp
+++ b/tests/test-interest.cpp
@@ -3,9 +3,12 @@
  * See COPYING for copyright and distribution information.
  */
 
-#include <boost/test/unit_test.hpp>
-
 #include "interest.hpp"
+#include "data.hpp"
+#include "security/signature-sha256-with-rsa.hpp"
+#include "security/signature-sha256.hpp"
+
+#include <boost/test/unit_test.hpp>
 
 using namespace std;
 namespace ndn {
@@ -230,6 +233,49 @@
   BOOST_CHECK_EQUAL(&payload, &wireBlock);
 }
 
+BOOST_AUTO_TEST_CASE(MatchesData)
+{
+  Interest interest;
+  interest.setName("ndn:/A")
+          .setMinSuffixComponents(2)
+          .setMaxSuffixComponents(2)
+          .setPublisherPublicKeyLocator(KeyLocator("ndn:/B"))
+          .setExclude(Exclude().excludeBefore(name::Component("C")));
+
+  Data data("ndn:/A/D");
+  SignatureSha256WithRsa signature;
+  signature.setKeyLocator(KeyLocator("ndn:/B"));
+  data.setSignature(signature);
+  BOOST_CHECK_EQUAL(interest.matchesData(data), true);
+
+  Data data1 = data;
+  data1.setName("ndn:/A");// violates MinSuffixComponents
+  BOOST_CHECK_EQUAL(interest.matchesData(data1), false);
+
+  Data data2 = data;
+  data2.setName("ndn:/A/E/F");// violates MaxSuffixComponents
+  BOOST_CHECK_EQUAL(interest.matchesData(data2), false);
+
+  Data data3 = data;
+  SignatureSha256WithRsa signature3;
+  signature3.setKeyLocator(KeyLocator("ndn:/G"));// violates PublisherPublicKeyLocator
+  data3.setSignature(signature3);
+  BOOST_CHECK_EQUAL(interest.matchesData(data3), false);
+
+  Data data4 = data;
+  SignatureSha256 signature4;// violates PublisherPublicKeyLocator
+  data4.setSignature(signature4);
+  BOOST_CHECK_EQUAL(interest.matchesData(data4), false);
+
+  Data data5 = data;
+  data5.setName("ndn:/A/C");// violates Exclude
+  BOOST_CHECK_EQUAL(interest.matchesData(data5), false);
+
+  Data data6 = data;
+  data6.setName("ndn:/H/I");// violates Name
+  BOOST_CHECK_EQUAL(interest.matchesData(data6), false);
+}
+
 BOOST_AUTO_TEST_SUITE_END()
 
 } // namespace ndn
