]> granicus.if.org Git - python/commitdiff
Disabled test_xmlrpc:test_404. It's causing lots of false alarms.
authorChristian Heimes <christian@cheimes.de>
Sat, 19 Jan 2008 16:39:27 +0000 (16:39 +0000)
committerChristian Heimes <christian@cheimes.de>
Sat, 19 Jan 2008 16:39:27 +0000 (16:39 +0000)
I also disabled a test in test_ssl which requires network access to svn.python.org. This fixes a bug Skip has reported a while ago.

Lib/test/test_socket.py
Lib/test/test_ssl.py
Lib/test/test_xmlrpc.py

index d98e546298a07a6f2aa86d2f2b0978880fb2c900..660d85355fa4f85f1203a10a5dd3bbf78e41be82 100644 (file)
@@ -279,7 +279,6 @@ class GeneralModuleTests(unittest.TestCase):
 
     def testRefCountGetNameInfo(self):
         # Testing reference count for getnameinfo
-        import sys
         if hasattr(sys, "getrefcount"):
             try:
                 # On some versions, this loses a reference
index 7e78b4c9cff4f02888aecf2ad3d7d77a603f77cb..a82aa6da187c3b7835bae0e8266366e34d390ef9 100644 (file)
@@ -37,7 +37,8 @@ def handle_error(prefix):
 class BasicTests(unittest.TestCase):
 
     def testSSLconnect(self):
-        import os
+        if not test_support.is_resource_enabled('network'):
+            return
         s = ssl.wrap_socket(socket.socket(socket.AF_INET),
                             cert_reqs=ssl.CERT_NONE)
         s.connect(("svn.python.org", 443))
@@ -101,7 +102,6 @@ class BasicTests(unittest.TestCase):
 class NetworkTests(unittest.TestCase):
 
     def testConnect(self):
-        import os
         s = ssl.wrap_socket(socket.socket(socket.AF_INET),
                             cert_reqs=ssl.CERT_NONE)
         s.connect(("svn.python.org", 443))
index eb39d27759c3de90152bb12d992f7bb0e76e0a35..4dd3316ffa0cdcdb523a8d8c87365b38b41bfe48 100644 (file)
@@ -392,7 +392,8 @@ class SimpleServerTestCase(unittest.TestCase):
                 # protocol error; provide additional information in test output
                 self.fail("%s\n%s" % (e, e.headers))
 
-    def test_404(self):
+    # [ch] The test 404 is causing lots of false alarms.
+    def XXXtest_404(self):
         # send POST with httplib, it should return 404 header and
         # 'Not Found' message.
         conn = httplib.HTTPConnection('localhost', PORT)