aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorAldo Cortesi <aldo@nullcube.com>2016-07-16 10:00:34 +1200
committerAldo Cortesi <aldo@nullcube.com>2016-07-16 10:19:06 +1200
commit5f23d4f5ca49a3f6cfbcfd9f4e444150a25844b0 (patch)
tree8050cfc0a99a383b82fe3e423c9fc3e2ad43b44c /test
parent5a60f32c5510610935af1549022b3f7948002721 (diff)
downloadmitmproxy-5f23d4f5ca49a3f6cfbcfd9f4e444150a25844b0.tar.gz
mitmproxy-5f23d4f5ca49a3f6cfbcfd9f4e444150a25844b0.tar.bz2
mitmproxy-5f23d4f5ca49a3f6cfbcfd9f4e444150a25844b0.zip
add_event -> add_log throughout project
"Event" is terribly over-loaded in the project, and "log" is straight-forward and self-explanatory.
Diffstat (limited to 'test')
-rw-r--r--test/mitmproxy/mastertest.py2
-rw-r--r--test/mitmproxy/test_dump.py3
-rw-r--r--test/mitmproxy/test_examples.py2
-rw-r--r--test/mitmproxy/tservers.py2
4 files changed, 5 insertions, 4 deletions
diff --git a/test/mitmproxy/mastertest.py b/test/mitmproxy/mastertest.py
index 240f6a73..d1fe8cb4 100644
--- a/test/mitmproxy/mastertest.py
+++ b/test/mitmproxy/mastertest.py
@@ -47,5 +47,5 @@ class RecordingMaster(master.FlowMaster):
master.FlowMaster.__init__(self, *args, **kwargs)
self.event_log = []
- def add_event(self, e, level):
+ def add_log(self, e, level):
self.event_log.append((level, e))
diff --git a/test/mitmproxy/test_dump.py b/test/mitmproxy/test_dump.py
index 201386e3..c94630a9 100644
--- a/test/mitmproxy/test_dump.py
+++ b/test/mitmproxy/test_dump.py
@@ -235,7 +235,8 @@ class TestDumpMaster(mastertest.MasterTest):
ret = self.dummy_cycle(
self.mkmaster(
None,
- scripts=[tutils.test_data.path("data/scripts/all.py")], verbosity=1
+ scripts=[tutils.test_data.path("data/scripts/all.py")],
+ verbosity=2
),
1, b"",
)
diff --git a/test/mitmproxy/test_examples.py b/test/mitmproxy/test_examples.py
index f8646336..0ec85f52 100644
--- a/test/mitmproxy/test_examples.py
+++ b/test/mitmproxy/test_examples.py
@@ -21,7 +21,7 @@ class ScriptError(Exception):
class RaiseMaster(master.FlowMaster):
- def add_event(self, e, level):
+ def add_log(self, e, level):
if level in ("warn", "error"):
raise ScriptError(e)
diff --git a/test/mitmproxy/tservers.py b/test/mitmproxy/tservers.py
index 69a50b9d..9a66984b 100644
--- a/test/mitmproxy/tservers.py
+++ b/test/mitmproxy/tservers.py
@@ -42,7 +42,7 @@ class TestMaster(flow.FlowMaster):
def clear_log(self):
self.tlog = []
- def add_event(self, message, level=None):
+ def add_log(self, message, level=None):
self.tlog.append(message)