aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorUjjwal Verma <ujjwalverma1111@gmail.com>2017-03-09 23:33:11 +0530
committerUjjwal Verma <ujjwalverma1111@gmail.com>2017-03-09 23:33:11 +0530
commit25703f8c539fb954efb2551f6f5050018d623501 (patch)
tree182e1ee13906ddf8a4ccd2d46e56bc70ede95def /test
parent07a8c4987a5281e1220204f6e425afe559d52383 (diff)
downloadmitmproxy-25703f8c539fb954efb2551f6f5050018d623501.tar.gz
mitmproxy-25703f8c539fb954efb2551f6f5050018d623501.tar.bz2
mitmproxy-25703f8c539fb954efb2551f6f5050018d623501.zip
Fixed Replacement test
Diffstat (limited to 'test')
-rw-r--r--test/mitmproxy/addons/test_replace.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/test/mitmproxy/addons/test_replace.py b/test/mitmproxy/addons/test_replace.py
index 8c280c51..79ef7bac 100644
--- a/test/mitmproxy/addons/test_replace.py
+++ b/test/mitmproxy/addons/test_replace.py
@@ -72,7 +72,7 @@ class TestUpstreamProxy(tservers.HTTPUpstreamProxyTest):
class TestReplaceFile:
def test_simple(self):
- r = replace.ReplaceFile()
+ r = replace.Replace()
with tutils.tmpdir() as td:
rp = os.path.join(td, "replacement")
with open(rp, "w") as f:
@@ -80,10 +80,10 @@ class TestReplaceFile:
with taddons.context() as tctx:
tctx.configure(
r,
- replacement_files = [
- "/~q/foo/" + rp,
- "/~s/foo/" + rp,
- "/~b nonexistent/nonexistent/nonexistent",
+ replacements = [
+ "/~q/foo/@" + rp,
+ "/~s/foo/@" + rp,
+ "/~b nonexistent/nonexistent/@nonexistent",
]
)
f = tflow.tflow()