diff options
-rw-r--r-- | Lib/test/test_httplib.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Lib/test/test_httplib.py b/Lib/test/test_httplib.py index bbcdd8b..632c2bc 100644 --- a/Lib/test/test_httplib.py +++ b/Lib/test/test_httplib.py @@ -201,8 +201,9 @@ class HTTPSTimeoutTest(TestCase): def test_attributes(self): # simple test to check it's storing it - h = httplib.HTTPSConnection(HOST, PORT, timeout=30) - self.assertEqual(h.timeout, 30) + if hasattr(httplib, 'HTTPSConnection'): + h = httplib.HTTPSConnection(HOST, PORT, timeout=30) + self.assertEqual(h.timeout, 30) def test_main(verbose=None): test_support.run_unittest(HeaderTests, OfflineTest, BasicTest, TimeoutTest, HTTPSTimeoutTest) |