Browse Source

[2387] Re-enable previously disabled tests

Mukund Sivaraman 12 years ago
parent
commit
167b544c41
1 changed files with 5 additions and 4 deletions
  1. 5 4
      src/lib/dns/tests/rdata_dnskey_unittest.cc

+ 5 - 4
src/lib/dns/tests/rdata_dnskey_unittest.cc

@@ -74,14 +74,15 @@ TEST_F(Rdata_DNSKEY_Test, badText) {
     // Key data too short for algorithm=1
     // Key data too short for algorithm=1
     EXPECT_THROW(generic::DNSKEY("1 1 1 YQ=="),
     EXPECT_THROW(generic::DNSKEY("1 1 1 YQ=="),
                  InvalidRdataLength);
                  InvalidRdataLength);
-}
 
 
-TEST_F(Rdata_DNSKEY_Test, DISABLED_badText) {
-    // Should this be allowed?  Probably not.  But the test currently fails.
+    // Missing algorithm
     EXPECT_THROW(generic::DNSKEY("257 3 5BEAAEFTd"),
     EXPECT_THROW(generic::DNSKEY("257 3 5BEAAEFTd"),
                  InvalidRdataText);
                  InvalidRdataText);
+
     // How about this?  It's even more confusing for the parser because
     // How about this?  It's even more confusing for the parser because
-    // it could be ambiguous '51 EAAA' vs '5 1EAA..'
+    // it could be ambiguous '51 EAAA' vs '5 1EAA..'. But we first parse
+    // the other fields before we parse the public key, so we reject
+    // this.
     EXPECT_THROW(generic::DNSKEY("257 3 51EAAEFTd"),
     EXPECT_THROW(generic::DNSKEY("257 3 51EAAEFTd"),
                  InvalidRdataText);
                  InvalidRdataText);
 }
 }