summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_socket.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_socket.py')
-rw-r--r--Lib/test/test_socket.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/test/test_socket.py b/Lib/test/test_socket.py
index 32084da..6bdb6c9 100644
--- a/Lib/test/test_socket.py
+++ b/Lib/test/test_socket.py
@@ -667,6 +667,8 @@ class GeneralModuleTests(unittest.TestCase):
type=socket.SOCK_STREAM, proto=0,
flags=socket.AI_PASSIVE)
self.assertEqual(a, b)
+ # Issue #6697.
+ self.assertRaises(UnicodeEncodeError, socket.getaddrinfo, 'localhost', '\uD800')
def test_getnameinfo(self):
# only IP addresses are allowed