BIND 10 trac2435, updated. 9bc254508724e55db2ce9624a0a9322f4d3d9f31 [2435] Test use of NO_WILDCARD option

BIND 10 source code commits bind10-changes at lists.isc.org
Thu Jan 10 13:51:24 UTC 2013


The branch, trac2435 has been updated
       via  9bc254508724e55db2ce9624a0a9322f4d3d9f31 (commit)
       via  00980e1e05152e7b44968438dc846ea41f43c113 (commit)
      from  355fb4b538030ec31101edd4b8ea6e2ae2d90e65 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 9bc254508724e55db2ce9624a0a9322f4d3d9f31
Author: Mukund Sivaraman <muks at isc.org>
Date:   Thu Jan 10 19:20:19 2013 +0530

    [2435] Test use of NO_WILDCARD option

commit 00980e1e05152e7b44968438dc846ea41f43c113
Author: Mukund Sivaraman <muks at isc.org>
Date:   Thu Jan 10 19:19:28 2013 +0530

    [2435] Update comment

-----------------------------------------------------------------------

Summary of changes:
 src/lib/datasrc/tests/database_unittest.cc |   25 +++++++++++++++++++++----
 1 file changed, 21 insertions(+), 4 deletions(-)

-----------------------------------------------------------------------
diff --git a/src/lib/datasrc/tests/database_unittest.cc b/src/lib/datasrc/tests/database_unittest.cc
index b4ad0bc..b7fdf8b 100644
--- a/src/lib/datasrc/tests/database_unittest.cc
+++ b/src/lib/datasrc/tests/database_unittest.cc
@@ -4242,15 +4242,32 @@ TYPED_TEST(RRsetCollectionTest, find) {
     // Is this correct behavior?
     EXPECT_FALSE(rrset);
 
-    // With the FIND_GLUE_OK passed to ZoneFinder's find(),
-    // "delegation.example.org." with type NS should return the NS
-    // record. Without FIND_GLUE_OK, ZoneFinder's find() would return
-    // DELEGATION and the find() below would return nothing.
+    // With the FIND_GLUE_OK option passed to ZoneFinder's find(),
+    // searching for "delegation.example.org." with type NS should
+    // return the NS record. Without FIND_GLUE_OK, ZoneFinder's find()
+    // would return DELEGATION and the find() below would return
+    // nothing.
     rrset = this->collection->find(Name("delegation.example.org"),
                                    this->qclass_, RRType::NS());
     ASSERT_TRUE(rrset);
     EXPECT_EQ(RRType::NS(), rrset->getType());
     EXPECT_EQ(Name("delegation.example.org"), rrset->getName());
+
+    // With the NO_WILDCARD option passed to ZoneFinder's find(),
+    // searching for some "foo.wildcard.example.org." would make
+    // ZoneFinder's find() return NXDOMAIN, and the find() below should
+    // return nothing.
+    rrset = this->collection->find(Name("foo.wild.example.org"),
+                                   this->qclass_, RRType::A());
+    EXPECT_FALSE(rrset);
+
+    // Searching directly for "*.wild.example.org." should return the
+    // record.
+    rrset = this->collection->find(Name("*.wild.example.org"),
+                                   this->qclass_, RRType::A());
+    ASSERT_TRUE(rrset);
+    EXPECT_EQ(RRType::A(), rrset->getType());
+    EXPECT_EQ(Name("*.wild.example.org"), rrset->getName());
 }
 
 TYPED_TEST(RRsetCollectionTest, iteratorTest) {



More information about the bind10-changes mailing list