From 0426eccfd8c175d0ece6da92dd8425370fc8de6c Mon Sep 17 00:00:00 2001 From: Maximilian Hils Date: Sun, 28 Sep 2014 03:55:16 +0200 Subject: [PATCH] fix tests --- setup.py | 2 +- test/test_test.py | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/setup.py b/setup.py index 2ff2d0be0..1dd0e7d2d 100644 --- a/setup.py +++ b/setup.py @@ -99,7 +99,7 @@ setup( ], install_requires=[ 'netlib>=%s' % version.MINORVERSION, - "requests>=2.4.0", + "requests>=2.4.1", "Flask>=0.10.1" ], extras_require={ diff --git a/test/test_test.py b/test/test_test.py index d26ce07be..0a05f1c12 100644 --- a/test/test_test.py +++ b/test/test_test.py @@ -2,7 +2,6 @@ import logging import requests from libpathod import test import tutils -from requests.packages.urllib3.exceptions import ProtocolError logging.disable(logging.CRITICAL) class TestDaemonManual: @@ -11,7 +10,7 @@ class TestDaemonManual: rsp = requests.get("http://localhost:%s/p/202:da"%d.port) assert rsp.ok assert rsp.status_code == 202 - tutils.raises(ProtocolError, requests.get, "http://localhost:%s/p/202:da"%d.port) + tutils.raises(requests.ConnectionError, requests.get, "http://localhost:%s/p/202:da"%d.port) def test_startstop_ssl(self): d = test.Daemon(ssl=True) @@ -19,7 +18,7 @@ class TestDaemonManual: assert rsp.ok assert rsp.status_code == 202 d.shutdown() - tutils.raises(ProtocolError, requests.get, "http://localhost:%s/p/202:da"%d.port) + tutils.raises(requests.ConnectionError, requests.get, "http://localhost:%s/p/202:da"%d.port) def test_startstop_ssl_explicit(self): ssloptions = dict( @@ -32,6 +31,6 @@ class TestDaemonManual: assert rsp.ok assert rsp.status_code == 202 d.shutdown() - tutils.raises(ProtocolError, requests.get, "http://localhost:%s/p/202:da"%d.port) + tutils.raises(requests.ConnectionError, requests.get, "http://localhost:%s/p/202:da"%d.port)