diff options
author | Aldo Cortesi <aldo@nullcube.com> | 2015-06-04 17:18:06 +1200 |
---|---|---|
committer | Aldo Cortesi <aldo@nullcube.com> | 2015-06-04 17:18:06 +1200 |
commit | 9fda74c65a632bda5176e2ccafbbcab2af27d77d (patch) | |
tree | a37c633bda76ae3f2c623bf1d14355279c0631d9 /test/test_language_actions.py | |
parent | 5bee061849b9e48d097b2aba3613e38f7282f36b (diff) | |
download | mitmproxy-9fda74c65a632bda5176e2ccafbbcab2af27d77d.tar.gz mitmproxy-9fda74c65a632bda5176e2ccafbbcab2af27d77d.tar.bz2 mitmproxy-9fda74c65a632bda5176e2ccafbbcab2af27d77d.zip |
Clarify language API, stub out nested websocket frames
Diffstat (limited to 'test/test_language_actions.py')
-rw-r--r-- | test/test_language_actions.py | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/test/test_language_actions.py b/test/test_language_actions.py index 16d54806..b0d97887 100644 --- a/test/test_language_actions.py +++ b/test/test_language_actions.py @@ -5,7 +5,7 @@ from libpathod import language def parse_request(s): - return language.parse_requests(s)[0] + return language.parse_pathoc(s)[0] def test_unique_name(): @@ -14,10 +14,10 @@ def test_unique_name(): class TestDisconnects: - def test_parse_response(self): - a = language.parse_response("400:d0").actions[0] + def test_parse_pathod(self): + a = language.parse_pathod("400:d0").actions[0] assert a.spec() == "d0" - a = language.parse_response("400:dr").actions[0] + a = language.parse_pathod("400:dr").actions[0] assert a.spec() == "dr" def test_at(self): @@ -39,13 +39,13 @@ class TestDisconnects: class TestInject: - def test_parse_response(self): - a = language.parse_response("400:ir,@100").actions[0] + def test_parse_pathod(self): + a = language.parse_pathod("400:ir,@100").actions[0] assert a.offset == "r" assert a.value.datatype == "bytes" assert a.value.usize == 100 - a = language.parse_response("400:ia,@100").actions[0] + a = language.parse_pathod("400:ia,@100").actions[0] assert a.offset == "a" def test_at(self): @@ -60,7 +60,7 @@ class TestInject: def test_serve(self): s = cStringIO.StringIO() - r = language.parse_response("400:i0,'foo'") + r = language.parse_pathod("400:i0,'foo'") assert language.serve(r, s, {}) def test_spec(self): @@ -77,7 +77,7 @@ class TestInject: class TestPauses: - def test_parse_response(self): + def test_parse_pathod(self): e = actions.PauseAt.expr() v = e.parseString("p10,10")[0] assert v.seconds == 10 @@ -93,7 +93,7 @@ class TestPauses: assert v.offset == "a" def test_request(self): - r = language.parse_response('400:p10,10') + r = language.parse_pathod('400:p10,10') assert r.actions[0].spec() == "p10,10" def test_spec(self): |