Skip to content

Commit 2e601c5

Browse files
serhiy-storchakaned-deily
authored andcommitted
[3.6] bpo-33759: Fix test.test_xmlrpc.ServerProxyTestCase. (GH-7362) (GH-7375)
It depended on a global variable set by other tests.. (cherry picked from commit 7cfd8c6) Co-authored-by: Serhiy Storchaka <[email protected]>
1 parent d18b13d commit 2e601c5

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

Lib/test/test_xmlrpc.py

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1179,13 +1179,9 @@ def test_gzip_decode_limit(self):
11791179
class ServerProxyTestCase(unittest.TestCase):
11801180
def setUp(self):
11811181
unittest.TestCase.setUp(self)
1182-
if threading:
1183-
self.url = URL
1184-
else:
1185-
# Without threading, http_server() and http_multi_server() will not
1186-
# be executed and URL is still equal to None. 'http://' is a just
1187-
# enough to choose the scheme (HTTP)
1188-
self.url = 'http://'
1182+
# Actual value of the URL doesn't matter if it is a string in
1183+
# the correct format.
1184+
self.url = 'http://fake.localhost'
11891185

11901186
def test_close(self):
11911187
p = xmlrpclib.ServerProxy(self.url)

0 commit comments

Comments
 (0)