aboutsummaryrefslogtreecommitdiffstats
path: root/test/tutils.py
diff options
context:
space:
mode:
authorAldo Cortesi <aldo@nullcube.com>2011-06-02 10:45:17 +1200
committerAldo Cortesi <aldo@nullcube.com>2011-06-02 10:45:17 +1200
commit62f9864395fcb9933992257d5beabf84e532f85f (patch)
treeafe048a485913801fd04f8e0baf9678234cedfcc /test/tutils.py
parent1de5209340cf0f032a93244bee1696abbb879154 (diff)
parent07110bbbf192339b52d1067b531d0cea20b245d2 (diff)
downloadmitmproxy-62f9864395fcb9933992257d5beabf84e532f85f.tar.gz
mitmproxy-62f9864395fcb9933992257d5beabf84e532f85f.tar.bz2
mitmproxy-62f9864395fcb9933992257d5beabf84e532f85f.zip
Merge branch 'master' of github.com:cortesi/mitmproxy
Diffstat (limited to 'test/tutils.py')
-rw-r--r--test/tutils.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/tutils.py b/test/tutils.py
index fea7f224..2327bdb9 100644
--- a/test/tutils.py
+++ b/test/tutils.py
@@ -32,6 +32,13 @@ def tflow_full():
return f
+def tflow_err():
+ r = treq()
+ f = flow.Flow(r)
+ f.error = proxy.Error(r, "error")
+ return f
+
+
# Yes, the random ports are horrible. During development, sockets are often not
# properly closed during error conditions, which means you have to wait until
# you can re-bind to the same port. This is a pain in the ass, so we just pick