summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTim Peters <tim.peters@gmail.com>2001-12-07 21:35:42 (GMT)
committerTim Peters <tim.peters@gmail.com>2001-12-07 21:35:42 (GMT)
commitcbfc0343fc66cb4bd7f962698c81ff74b94ea554 (patch)
tree2da8d617de1591fa94219f6a182ad4615346690a
parent78f0dd3397f77df3b4b3d13c686a33af14a70af8 (diff)
downloadcpython-cbfc0343fc66cb4bd7f962698c81ff74b94ea554.zip
cpython-cbfc0343fc66cb4bd7f962698c81ff74b94ea554.tar.gz
cpython-cbfc0343fc66cb4bd7f962698c81ff74b94ea554.tar.bz2
SF patch 490393: test___all__ and Jython; from Finn Bock.
Don't even try to import _socket when running under Jython.
-rw-r--r--Lib/test/test___all__.py7
1 files changed, 4 insertions, 3 deletions
diff --git a/Lib/test/test___all__.py b/Lib/test/test___all__.py
index 08df6b2..4a41036 100644
--- a/Lib/test/test___all__.py
+++ b/Lib/test/test___all__.py
@@ -35,9 +35,10 @@ def check_all(modname):
all.sort()
verify(keys==all, "%s != %s" % (keys, all))
-# In case _socket fails to build, make this test fail more gracefully
-# than an AttributeError somewhere deep in CGIHTTPServer.
-import _socket
+if not sys.platform.startswith('java'):
+ # In case _socket fails to build, make this test fail more gracefully
+ # than an AttributeError somewhere deep in CGIHTTPServer.
+ import _socket
check_all("BaseHTTPServer")
check_all("CGIHTTPServer")