summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_xmlrpc_net.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_xmlrpc_net.py')
-rw-r--r--Lib/test/test_xmlrpc_net.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/Lib/test/test_xmlrpc_net.py b/Lib/test/test_xmlrpc_net.py
index b8426ac..9ed8f8d 100644
--- a/Lib/test/test_xmlrpc_net.py
+++ b/Lib/test/test_xmlrpc_net.py
@@ -1,4 +1,4 @@
-#!/usr/bin/env python
+#!/usr/bin/env python3
import collections
import errno
@@ -14,6 +14,7 @@ class CurrentTimeTest(unittest.TestCase):
def test_current_time(self):
# Get the current time from xmlrpc.com. This code exercises
# the minimal HTTP functionality in xmlrpclib.
+ self.skipTest("time.xmlrpc.com is unreliable")
server = xmlrpclib.ServerProxy("http://time.xmlrpc.com/RPC2")
try:
t0 = server.currentTime.getCurrentTime()
@@ -38,17 +39,17 @@ class CurrentTimeTest(unittest.TestCase):
def test_python_builders(self):
# Get the list of builders from the XMLRPC buildbot interface at
# python.org.
- self.skipTest("XMLRPC interface removed in Buildbot 0.8.2")
server = xmlrpclib.ServerProxy("http://www.python.org/dev/buildbot/all/xmlrpc/")
try:
builders = server.getAllBuilders()
except socket.error as e:
self.skipTest("network error: %s" % e)
return
+ self.addCleanup(lambda: server('close')())
# Perform a minimal sanity check on the result, just to be sure
# the request means what we think it means.
- self.assertTrue(isinstance(builders, collections.Sequence), type(builders))
+ self.assertIsInstance(builders, collections.Sequence)
self.assertTrue([x for x in builders if "3.x" in x], builders)