summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_logging.py
diff options
context:
space:
mode:
authorFlorent Xicluna <florent.xicluna@gmail.com>2010-08-15 20:16:27 (GMT)
committerFlorent Xicluna <florent.xicluna@gmail.com>2010-08-15 20:16:27 (GMT)
commitdc692740a8609b535b44931b93a290d594b92fd0 (patch)
tree26e19a2a51d1bbe599c7ad91bcfc4834bd9281e3 /Lib/test/test_logging.py
parenta0241c8587fb15ccfb161762754e65c4cc11d421 (diff)
downloadcpython-dc692740a8609b535b44931b93a290d594b92fd0.zip
cpython-dc692740a8609b535b44931b93a290d594b92fd0.tar.gz
cpython-dc692740a8609b535b44931b93a290d594b92fd0.tar.bz2
Replace the deprecated ConfigParser.readfp() method, and fix the incomplete merge in r82293.
Diffstat (limited to 'Lib/test/test_logging.py')
-rw-r--r--Lib/test/test_logging.py7
1 files changed, 3 insertions, 4 deletions
diff --git a/Lib/test/test_logging.py b/Lib/test/test_logging.py
index d763459..511b2e0 100644
--- a/Lib/test/test_logging.py
+++ b/Lib/test/test_logging.py
@@ -38,8 +38,7 @@ from socketserver import ThreadingTCPServer, StreamRequestHandler
import struct
import sys
import tempfile
-from test.support import captured_stdout, run_with_locale, run_unittest,\
- find_unused_port
+from test.support import captured_stdout, run_with_locale, run_unittest
import textwrap
import unittest
import warnings
@@ -1666,8 +1665,8 @@ class ConfigDictTest(BaseTest):
@unittest.skipUnless(threading, 'listen() needs threading to work')
def setup_via_listener(self, text):
text = text.encode("utf-8")
- port = find_unused_port()
- t = logging.config.listen(port)
+ # Ask for a randomly assigned port (by using port 0)
+ t = logging.config.listen(0)
t.start()
t.ready.wait()
# Now get the port allocated