============================= test session starts ============================== platform linux -- Python 3.10.1, pytest-6.2.5, py-1.11.0, pluggy-0.13.1 rootdir: /build/python-dnspython/src/dnspython-2.1.0 collected 1124 items / 1 deselected / 1123 selected tests/test_address.py .... [ 0%] tests/test_async.py ..................F......... [ 2%] tests/test_bugs.py ........ [ 3%] tests/test_constants.py ..... [ 4%] tests/test_dnssec.py ................................... [ 7%] tests/test_doh.py sssssss [ 7%] tests/test_edns.py ........... [ 8%] tests/test_entropy.py ..... [ 9%] tests/test_exceptions.py ..... [ 9%] tests/test_flags.py ............ [ 10%] tests/test_generate.py ................. [ 12%] tests/test_grange.py .......... [ 13%] tests/test_immutable.py ......... [ 13%] tests/test_message.py .................................................. [ 18%] ........ [ 19%] tests/test_name.py ..................................................... [ 23%] ........................................................................ [ 30%] ............................................... [ 34%] tests/test_namedict.py ...................... [ 36%] tests/test_nsec3.py .. [ 36%] tests/test_nsec3_hash.py ... [ 36%] tests/test_ntoaaton.py ............................................. [ 40%] tests/test_processing_order.py .......... [ 41%] tests/test_query.py .....................ssssssssssss.. [ 44%] tests/test_rdata.py .................................................... [ 49%] ............................. [ 52%] tests/test_rdataset.py .................. [ 53%] tests/test_rdtypeandclass.py .......................... [ 55%] tests/test_rdtypeanydnskey.py .. [ 56%] tests/test_rdtypeanyeui.py ........................ [ 58%] tests/test_rdtypeanyloc.py .... [ 58%] tests/test_rdtypeanytkey.py .... [ 58%] tests/test_renderer.py .... [ 59%] tests/test_resolution.py .............................. [ 61%] tests/test_resolver.py .............................F.....F.......F..F.. [ 66%] F.......F..F..F............ss [ 68%] tests/test_resolver_override.py F............. [ 70%] tests/test_rrset.py ...................... [ 72%] tests/test_serial.py ........... [ 73%] tests/test_set.py ........................................ [ 76%] tests/test_svcb.py .............. [ 77%] tests/test_tokenizer.py ................................................ [ 82%] [ 82%] tests/test_transaction.py ....................................... [ 85%] tests/test_tsig.py ................ [ 87%] tests/test_tsigkeyring.py ....... [ 87%] tests/test_ttl.py ....... [ 88%] tests/test_update.py ....................... [ 90%] tests/test_wire.py ....... [ 91%] tests/test_xfr.py ........................ssss [ 93%] tests/test_zone.py ..................................................... [ 98%] .................... [100%] =================================== FAILURES =================================== ____________________________ AsyncTests.testResolve ____________________________ self = def testResolve(self): async def run(): answer = await dns.asyncresolver.resolve('dns.google.', 'A') return set([rdata.address for rdata in answer]) seen = self.async_run(run) self.assertTrue('8.8.8.8' in seen) > self.assertTrue('8.8.4.4' in seen) E AssertionError: False is not true tests/test_async.py:176: AssertionError ________________________ LiveResolverTests.testResolve _________________________ self = def testResolve(self): answer = dns.resolver.resolve('dns.google.', 'A') seen = set([rdata.address for rdata in answer]) self.assertTrue('8.8.8.8' in seen) > self.assertTrue('8.8.4.4' in seen) E AssertionError: False is not true tests/test_resolver.py:623: AssertionError _______________________ LiveResolverTests.testResolveTCP _______________________ self = def testResolveTCP(self): answer = dns.resolver.resolve('dns.google.', 'A', tcp=True) seen = set([rdata.address for rdata in answer]) self.assertTrue('8.8.8.8' in seen) > self.assertTrue('8.8.4.4' in seen) E AssertionError: False is not true tests/test_resolver.py:629: AssertionError ______________________ SelectResolverTestCase.testResolve ______________________ self = def testResolve(self): answer = dns.resolver.resolve('dns.google.', 'A') seen = set([rdata.address for rdata in answer]) self.assertTrue('8.8.8.8' in seen) > self.assertTrue('8.8.4.4' in seen) E AssertionError: False is not true tests/test_resolver.py:623: AssertionError __________________ SelectResolverTestCase.testResolveNXDOMAIN __________________ self = def testResolveNXDOMAIN(self): qname = dns.name.from_text('nxdomain.dnspython.org') qclass = dns.rdataclass.from_text('IN') qtype = dns.rdatatype.from_text('A') def bad(): answer = dns.resolver.resolve(qname, qtype) try: > dns.resolver.resolve(qname, qtype) tests/test_resolver.py:657: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ dns/resolver.py:1305: in resolve return get_default_resolver().resolve(qname, rdtype, rdclass, tcp, source, dns/resolver.py:1202: in resolve (answer, done) = resolution.query_result(response, None) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = response = , ex = None def query_result(self, response, ex): # # returns an (answer: Answer, end_loop: bool) tuple. # if ex: # Exception during I/O or from_wire() assert response is None self.errors.append((self.nameserver, self.tcp_attempt, self.port, ex, response)) if isinstance(ex, dns.exception.FormError) or \ isinstance(ex, EOFError) or \ isinstance(ex, OSError) or \ isinstance(ex, NotImplementedError): # This nameserver is no good, take it out of the mix. self.nameservers.remove(self.nameserver) elif isinstance(ex, dns.message.Truncated): if self.tcp_attempt: # Truncation with TCP is no good! self.nameservers.remove(self.nameserver) else: self.retry_with_tcp = True return (None, False) # We got an answer! assert response is not None rcode = response.rcode() if rcode == dns.rcode.NOERROR: try: answer = Answer(self.qname, self.rdtype, self.rdclass, response, self.nameserver, self.port) except Exception: # The nameserver is no good, take it out of the mix. self.nameservers.remove(self.nameserver) return (None, False) if self.resolver.cache: self.resolver.cache.put((self.qname, self.rdtype, self.rdclass), answer) if answer.rrset is None and self.raise_on_no_answer: > raise NoAnswer(response=answer.response) E dns.resolver.NoAnswer: The DNS response does not contain an answer to the question: nxdomain.dnspython.org. IN A dns/resolver.py:674: NoAnswer ____________________ SelectResolverTestCase.testResolveTCP _____________________ self = def testResolveTCP(self): answer = dns.resolver.resolve('dns.google.', 'A', tcp=True) seen = set([rdata.address for rdata in answer]) self.assertTrue('8.8.8.8' in seen) > self.assertTrue('8.8.4.4' in seen) E AssertionError: False is not true tests/test_resolver.py:629: AssertionError _______________________ PollResolverTestCase.testResolve _______________________ self = def testResolve(self): answer = dns.resolver.resolve('dns.google.', 'A') seen = set([rdata.address for rdata in answer]) self.assertTrue('8.8.8.8' in seen) > self.assertTrue('8.8.4.4' in seen) E AssertionError: False is not true tests/test_resolver.py:623: AssertionError ___________________ PollResolverTestCase.testResolveNXDOMAIN ___________________ self = def testResolveNXDOMAIN(self): qname = dns.name.from_text('nxdomain.dnspython.org') qclass = dns.rdataclass.from_text('IN') qtype = dns.rdatatype.from_text('A') def bad(): answer = dns.resolver.resolve(qname, qtype) try: > dns.resolver.resolve(qname, qtype) tests/test_resolver.py:657: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ dns/resolver.py:1305: in resolve return get_default_resolver().resolve(qname, rdtype, rdclass, tcp, source, dns/resolver.py:1202: in resolve (answer, done) = resolution.query_result(response, None) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = response = , ex = None def query_result(self, response, ex): # # returns an (answer: Answer, end_loop: bool) tuple. # if ex: # Exception during I/O or from_wire() assert response is None self.errors.append((self.nameserver, self.tcp_attempt, self.port, ex, response)) if isinstance(ex, dns.exception.FormError) or \ isinstance(ex, EOFError) or \ isinstance(ex, OSError) or \ isinstance(ex, NotImplementedError): # This nameserver is no good, take it out of the mix. self.nameservers.remove(self.nameserver) elif isinstance(ex, dns.message.Truncated): if self.tcp_attempt: # Truncation with TCP is no good! self.nameservers.remove(self.nameserver) else: self.retry_with_tcp = True return (None, False) # We got an answer! assert response is not None rcode = response.rcode() if rcode == dns.rcode.NOERROR: try: answer = Answer(self.qname, self.rdtype, self.rdclass, response, self.nameserver, self.port) except Exception: # The nameserver is no good, take it out of the mix. self.nameservers.remove(self.nameserver) return (None, False) if self.resolver.cache: self.resolver.cache.put((self.qname, self.rdtype, self.rdclass), answer) if answer.rrset is None and self.raise_on_no_answer: > raise NoAnswer(response=answer.response) E dns.resolver.NoAnswer: The DNS response does not contain an answer to the question: nxdomain.dnspython.org. IN A dns/resolver.py:674: NoAnswer _____________________ PollResolverTestCase.testResolveTCP ______________________ self = def testResolveTCP(self): answer = dns.resolver.resolve('dns.google.', 'A', tcp=True) seen = set([rdata.address for rdata in answer]) self.assertTrue('8.8.8.8' in seen) > self.assertTrue('8.8.4.4' in seen) E AssertionError: False is not true tests/test_resolver.py:629: AssertionError ____________ OverrideSystemResolverTestCase.test_basic_getaddrinfo _____________ self = @unittest.skipIf(sys.platform == 'win32', 'avoid windows original getaddrinfo issues') def test_basic_getaddrinfo(self): > self.assertTrue(self.equivalent('dns.google', 53, socket.AF_INET, socket.SOCK_DGRAM)) E AssertionError: False is not true tests/test_resolver_override.py:87: AssertionError =========================== short test summary info ============================ FAILED tests/test_async.py::AsyncTests::testResolve - AssertionError: False i... FAILED tests/test_resolver.py::LiveResolverTests::testResolve - AssertionErro... FAILED tests/test_resolver.py::LiveResolverTests::testResolveTCP - AssertionE... FAILED tests/test_resolver.py::SelectResolverTestCase::testResolve - Assertio... FAILED tests/test_resolver.py::SelectResolverTestCase::testResolveNXDOMAIN - ... FAILED tests/test_resolver.py::SelectResolverTestCase::testResolveTCP - Asser... FAILED tests/test_resolver.py::PollResolverTestCase::testResolve - AssertionE... FAILED tests/test_resolver.py::PollResolverTestCase::testResolveNXDOMAIN - dn... FAILED tests/test_resolver.py::PollResolverTestCase::testResolveTCP - Asserti... FAILED tests/test_resolver_override.py::OverrideSystemResolverTestCase::test_basic_getaddrinfo ========== 10 failed, 1088 passed, 25 skipped, 1 deselected in 44.97s ========== ==> ERROR: A failure occurred in check().  Aborting...