aboutsummaryrefslogtreecommitdiffstats
path: root/test/pathod/test_test.py
diff options
context:
space:
mode:
authorThomas Kriechbaumer <thomas@kriechbaumer.name>2017-02-01 16:48:46 +0100
committerThomas Kriechbaumer <thomas@kriechbaumer.name>2017-02-02 12:59:01 +0100
commitae008ed80b870688e4e0fe5ff305dc40c17458b4 (patch)
treee5d9fcd24a403f7491d0d6e42364bf91fdb2ac6e /test/pathod/test_test.py
parentec92d7f67e3c5960d9b30e067fb4ed1ae3fc8884 (diff)
downloadmitmproxy-ae008ed80b870688e4e0fe5ff305dc40c17458b4.tar.gz
mitmproxy-ae008ed80b870688e4e0fe5ff305dc40c17458b4.tar.bz2
mitmproxy-ae008ed80b870688e4e0fe5ff305dc40c17458b4.zip
replace tutils.raises with pytest.raises + shim
Diffstat (limited to 'test/pathod/test_test.py')
-rw-r--r--test/pathod/test_test.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/test/pathod/test_test.py b/test/pathod/test_test.py
index c2e1c6e9..40f45f53 100644
--- a/test/pathod/test_test.py
+++ b/test/pathod/test_test.py
@@ -1,5 +1,7 @@
import logging
import requests
+import pytest
+
from pathod import test
from mitmproxy.test import tutils
@@ -17,7 +19,7 @@ class TestDaemonManual:
rsp = requests.get("http://localhost:%s/p/202:da" % d.port)
assert rsp.ok
assert rsp.status_code == 202
- with tutils.raises(requests.ConnectionError):
+ with pytest.raises(requests.ConnectionError):
requests.get("http://localhost:%s/p/202:da" % d.port)
def test_startstop_ssl(self):
@@ -29,7 +31,7 @@ class TestDaemonManual:
assert rsp.ok
assert rsp.status_code == 202
d.shutdown()
- with tutils.raises(requests.ConnectionError):
+ with pytest.raises(requests.ConnectionError):
requests.get("http://localhost:%s/p/202:da" % d.port)
def test_startstop_ssl_explicit(self):
@@ -46,5 +48,5 @@ class TestDaemonManual:
assert rsp.ok
assert rsp.status_code == 202
d.shutdown()
- with tutils.raises(requests.ConnectionError):
+ with pytest.raises(requests.ConnectionError):
requests.get("http://localhost:%s/p/202:da" % d.port)