Provide a little better debug output (GH-6940) (#6942)
(cherry picked from commit 273f51f5ca
)
Co-authored-by: Barry Warsaw <barry@python.org>
This commit is contained in:
parent
6417d33633
commit
56882db4f7
|
@ -893,7 +893,7 @@ class GeneralModuleTests(unittest.TestCase):
|
||||||
)
|
)
|
||||||
for addr in ['0.1.1.~1', '1+.1.1.1', '::1q', '::1::2',
|
for addr in ['0.1.1.~1', '1+.1.1.1', '::1q', '::1::2',
|
||||||
'1:1:1:1:1:1:1:1:1']:
|
'1:1:1:1:1:1:1:1:1']:
|
||||||
with self.assertRaises(OSError):
|
with self.assertRaises(OSError, msg=addr):
|
||||||
socket.gethostbyname(addr)
|
socket.gethostbyname(addr)
|
||||||
with self.assertRaises(OSError, msg=explanation):
|
with self.assertRaises(OSError, msg=explanation):
|
||||||
socket.gethostbyaddr(addr)
|
socket.gethostbyaddr(addr)
|
||||||
|
|
Loading…
Reference in New Issue