aboutsummaryrefslogtreecommitdiffstats
path: root/mitmproxy/test/test_app.py
diff options
context:
space:
mode:
Diffstat (limited to 'mitmproxy/test/test_app.py')
-rw-r--r--mitmproxy/test/test_app.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/mitmproxy/test/test_app.py b/mitmproxy/test/test_app.py
new file mode 100644
index 00000000..577a70a5
--- /dev/null
+++ b/mitmproxy/test/test_app.py
@@ -0,0 +1,14 @@
+from . import tutils, tservers
+
+
+class TestApp(tservers.HTTPProxTest):
+
+ def test_basic(self):
+ assert self.app("/").status_code == 200
+
+ def test_cert(self):
+ with tutils.tmpdir() as d:
+ for ext in ["pem", "p12"]:
+ resp = self.app("/cert/%s" % ext)
+ assert resp.status_code == 200
+ assert resp.content