summaryrefslogtreecommitdiffhomepage
path: root/test/test_http.py
diff options
context:
space:
mode:
authorYen Chi Hsuan <[email protected]>2016-05-29 19:24:28 +0800
committerYen Chi Hsuan <[email protected]>2016-06-02 15:00:49 +0800
commit54fb1996812fa09f0f81ac28f42647e7706212b2 (patch)
tree0dae91542b82ded0540c261f7bc7ada225c15296 /test/test_http.py
parent8c32e5dc32f401ae22fa7087f3f3b1c9d6563835 (diff)
downloadyoutube-dl-54fb1996812fa09f0f81ac28f42647e7706212b2.tar.gz
youtube-dl-54fb1996812fa09f0f81ac28f42647e7706212b2.zip
[test/test_http] Fix getsockname() on Jython
Diffstat (limited to 'test/test_http.py')
-rw-r--r--test/test_http.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/test_http.py b/test/test_http.py
index 6b8493e5e..5076ced51 100644
--- a/test/test_http.py
+++ b/test/test_http.py
@@ -17,7 +17,7 @@ TEST_DIR = os.path.dirname(os.path.abspath(__file__))
def http_server_port(httpd):
- if os.name == 'java':
+ if os.name == 'java' and isinstance(httpd.socket, ssl.SSLSocket):
# In Jython SSLSocket is not a subclass of socket.socket
sock = httpd.socket.sock
else: