/usr/lib/python3/dist-packages/twisted/names/test
NameSizeModeActions
__pycache__/-0755rm
test_cache.py49160644editdlrm
test_client.py402550644editdlrm
test_common.py42060644editdlrm
test_dns.py1540600644editdlrm
test_examples.py53490644editdlrm
test_hosts.py85470644editdlrm
test_names.py430960644editdlrm
test_resolve.py10750644editdlrm
test_rfc1982.py139920644editdlrm
test_rootresolve.py256430644editdlrm
test_server.py412340644editdlrm
test_srvconnect.py101240644editdlrm
test_tap.py49610644editdlrm
test_util.py39150644editdlrm
__init__.py260644editdlrm
Edit: /usr/lib/python3/dist-packages/twisted/names/test/test_resolve.py (1075B)
# Copyright (c) Twisted Matrix Laboratories. # See LICENSE for details. """ Tests for L{twisted.names.resolve}. """ from twisted.trial.unittest import TestCase from twisted.names.error import DomainError from twisted.names.resolve import ResolverChain class ResolverChainTests(TestCase): """ Tests for L{twisted.names.resolve.ResolverChain} """ def test_emptyResolversList(self): """ L{ResolverChain._lookup} returns a L{DomainError} failure if its C{resolvers} list is empty. """ r = ResolverChain([]) d = r.lookupAddress('www.example.com') f = self.failureResultOf(d) self.assertIs(f.trap(DomainError), DomainError) def test_emptyResolversListLookupAllRecords(self): """ L{ResolverChain.lookupAllRecords} returns a L{DomainError} failure if its C{resolvers} list is empty. """ r = ResolverChain([]) d = r.lookupAllRecords('www.example.com') f = self.failureResultOf(d) self.assertIs(f.trap(DomainError), DomainError)