/usr/lib/python3/dist-packages/twisted/names/test
NameSizeModeActions
__pycache__/-0755rm
test_cache.py55810644editdlrm
test_client.py415010644editdlrm
test_common.py41240644editdlrm
test_dns.py1639950644editdlrm
test_examples.py53230644editdlrm
test_hosts.py99070644editdlrm
test_names.py489900644editdlrm
test_resolve.py10730644editdlrm
test_rfc1982.py138330644editdlrm
test_rootresolve.py256520644editdlrm
test_server.py416710644editdlrm
test_srvconnect.py94160644editdlrm
test_tap.py47540644editdlrm
test_util.py38390644editdlrm
__init__.py260644editdlrm
Edit: /usr/lib/python3/dist-packages/twisted/names/test/test_resolve.py (1073B)
# Copyright (c) Twisted Matrix Laboratories. # See LICENSE for details. """ Tests for L{twisted.names.resolve}. """ from twisted.names.error import DomainError from twisted.names.resolve import ResolverChain from twisted.trial.unittest import TestCase 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)