diff options
author | Maximilian Hils <git@maximilianhils.com> | 2016-02-15 23:00:11 +0100 |
---|---|---|
committer | Maximilian Hils <git@maximilianhils.com> | 2016-02-15 23:00:11 +0100 |
commit | 87d9afcf2e257eee7c5aa08c3f0dc64da79b0647 (patch) | |
tree | 71b10729d160f0269d02548d1ef9e183be1397d9 /test/mitmproxy/test_console_help.py | |
parent | 36f34f701991b5d474c005ec45e3b66e20f326a8 (diff) | |
parent | 3d9a5157e77b5a3237dc62994f4e3d4c75c2066e (diff) | |
download | mitmproxy-87d9afcf2e257eee7c5aa08c3f0dc64da79b0647.tar.gz mitmproxy-87d9afcf2e257eee7c5aa08c3f0dc64da79b0647.tar.bz2 mitmproxy-87d9afcf2e257eee7c5aa08c3f0dc64da79b0647.zip |
Merge pull request #937 from mhils/single-repo
Combine mitmproxy, pathod and netlib in a single repo.
Diffstat (limited to 'test/mitmproxy/test_console_help.py')
-rw-r--r-- | test/mitmproxy/test_console_help.py | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/test/mitmproxy/test_console_help.py b/test/mitmproxy/test_console_help.py new file mode 100644 index 00000000..f1a71faf --- /dev/null +++ b/test/mitmproxy/test_console_help.py @@ -0,0 +1,19 @@ +import os +from unittest.case import SkipTest +if os.name == "nt": + raise SkipTest("Skipped on Windows.") + +import libmproxy.console.help as help + + +class TestHelp: + + def test_helptext(self): + h = help.HelpView(None) + assert h.helptext() + + def test_keypress(self): + h = help.HelpView([1, 2, 3]) + assert not h.keypress((0, 0), "q") + assert not h.keypress((0, 0), "?") + assert h.keypress((0, 0), "o") == "o" |