From: Otto Moerbeek Date: Mon, 3 Apr 2023 07:20:12 +0000 (+0200) Subject: Regression tests should use new EDE X-Git-Tag: rec-4.9.0-alpha1~11^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F12698%2Fhead;p=thirdparty%2Fpdns.git Regression tests should use new EDE --- diff --git a/regression-tests.recursor-dnssec/test_AggressiveNSECCache.py b/regression-tests.recursor-dnssec/test_AggressiveNSECCache.py index 35588e33c6..2ff833efcd 100644 --- a/regression-tests.recursor-dnssec/test_AggressiveNSECCache.py +++ b/regression-tests.recursor-dnssec/test_AggressiveNSECCache.py @@ -93,7 +93,7 @@ class AggressiveNSECCacheBase(RecursorTest): self.assertEqual(res.edns, 0) self.assertEqual(len(res.options), 1) self.assertEqual(res.options[0].otype, 15) - self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(0, b'Result synthesized from aggressive NSEC cache (RFC8198)')) + self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(29, b'Result synthesized from aggressive NSEC cache (RFC8198)')) class AggressiveNSECCacheNSEC(AggressiveNSECCacheBase): _confdir = 'AggressiveNSECCacheNSEC' @@ -131,7 +131,7 @@ class AggressiveNSECCacheNSEC(AggressiveNSECCacheBase): self.assertEqual(res.edns, 0) self.assertEqual(len(res.options), 1) self.assertEqual(res.options[0].otype, 15) - self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(0, b'Result synthesized from aggressive NSEC cache (RFC8198)')) + self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(29, b'Result synthesized from aggressive NSEC cache (RFC8198)')) def testWildcard(self): self.wipe() @@ -158,7 +158,7 @@ class AggressiveNSECCacheNSEC(AggressiveNSECCacheBase): self.assertEqual(res.edns, 0) self.assertEqual(len(res.options), 1) self.assertEqual(res.options[0].otype, 15) - self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(0, b'Result synthesized from aggressive NSEC cache (RFC8198)')) + self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(29, b'Result synthesized from aggressive NSEC cache (RFC8198)')) # now we ask for a type that does not exist at the wildcard hits = self.getMetric('aggressive-nsec-cache-nsec-hits') @@ -173,7 +173,7 @@ class AggressiveNSECCacheNSEC(AggressiveNSECCacheBase): self.assertEqual(res.edns, 0) self.assertEqual(len(res.options), 1) self.assertEqual(res.options[0].otype, 15) - self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(0, b'Result synthesized from aggressive NSEC cache (RFC8198)')) + self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(29, b'Result synthesized from aggressive NSEC cache (RFC8198)')) # we can also ask a different type, for a different name that is covered # by the NSEC and matches the wildcard (but the type does not exist) @@ -189,7 +189,7 @@ class AggressiveNSECCacheNSEC(AggressiveNSECCacheBase): self.assertEqual(res.edns, 0) self.assertEqual(len(res.options), 1) self.assertEqual(res.options[0].otype, 15) - self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(0, b'Result synthesized from aggressive NSEC cache (RFC8198)')) + self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(29, b'Result synthesized from aggressive NSEC cache (RFC8198)')) def test_Bogus(self): self.wipe() @@ -303,7 +303,7 @@ class AggressiveNSECCacheNSEC3(AggressiveNSECCacheBase): self.assertEqual(res.edns, 0) self.assertEqual(len(res.options), 1) self.assertEqual(res.options[0].otype, 15) - self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(0, b'Result synthesized from aggressive NSEC cache (RFC8198)')) + self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(29, b'Result synthesized from aggressive NSEC cache (RFC8198)')) def testWildcard(self): self.wipe() @@ -336,7 +336,7 @@ class AggressiveNSECCacheNSEC3(AggressiveNSECCacheBase): self.assertEqual(res.edns, 0) self.assertEqual(len(res.options), 1) self.assertEqual(res.options[0].otype, 15) - self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(0, b'Result synthesized from aggressive NSEC cache (RFC8198)')) + self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(29, b'Result synthesized from aggressive NSEC cache (RFC8198)')) # now we ask for a type that does not exist at the wildcard nbQueries = self.getMetric('all-outqueries') @@ -349,7 +349,7 @@ class AggressiveNSECCacheNSEC3(AggressiveNSECCacheBase): self.assertEqual(res.edns, 0) self.assertEqual(len(res.options), 1) self.assertEqual(res.options[0].otype, 15) - self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(0, b'Result synthesized from aggressive NSEC cache (RFC8198)')) + self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(29, b'Result synthesized from aggressive NSEC cache (RFC8198)')) # we can also ask a different type, for a different name that is covered # by the NSEC3s and matches the wildcard (but the type does not exist) @@ -363,7 +363,7 @@ class AggressiveNSECCacheNSEC3(AggressiveNSECCacheBase): self.assertEqual(res.edns, 0) self.assertEqual(len(res.options), 1) self.assertEqual(res.options[0].otype, 15) - self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(0, b'Result synthesized from aggressive NSEC cache (RFC8198)')) + self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(29, b'Result synthesized from aggressive NSEC cache (RFC8198)')) def test_OptOut(self): self.wipe() diff --git a/regression-tests.recursor-dnssec/test_RootNXTrust.py b/regression-tests.recursor-dnssec/test_RootNXTrust.py index 21254b4db2..cb1133641b 100644 --- a/regression-tests.recursor-dnssec/test_RootNXTrust.py +++ b/regression-tests.recursor-dnssec/test_RootNXTrust.py @@ -138,4 +138,4 @@ extended-resolution-errors self.assertEqual(res.edns, 0) self.assertEqual(len(res.options), 1) self.assertEqual(res.options[0].otype, 15) - self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(0, b'Result synthesized by root-nx-trust')) + self.assertEqual(res.options[0], extendederrors.ExtendedErrorOption(29, b'Result synthesized by root-nx-trust'))