def test_hostname_does_not_resolve(self):
"""
Specifying a hostname which cannot be resolved to an
IP address will result in an ``DNSLookupError``.
"""
with ExpectedException(DNSLookupError, "DNS lookup failed: no results "
"for hostname lookup: doesnotresolve."):
self._authorized_request(
token="test",
headers=Headers({}),
kubernetes_host=b"doesnotresolve"
)
评论列表
文章目录