summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_support.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_support.py')
-rw-r--r--Lib/test/test_support.py6
1 files changed, 2 insertions, 4 deletions
diff --git a/Lib/test/test_support.py b/Lib/test/test_support.py
index 4a8f3c5..cb664ba 100644
--- a/Lib/test/test_support.py
+++ b/Lib/test/test_support.py
@@ -91,14 +91,12 @@ class TestSupport(unittest.TestCase):
support.rmtree('__pycache__')
def test_HOST(self):
- s = socket.socket()
- s.bind((support.HOST, 0))
+ s = socket.create_server((support.HOST, 0))
s.close()
def test_find_unused_port(self):
port = support.find_unused_port()
- s = socket.socket()
- s.bind((support.HOST, port))
+ s = socket.create_server((support.HOST, port))
s.close()
def test_bind_port(self):