From 0a90a3eaba98d9f6aa656e78847d4001d0a005c8 Mon Sep 17 00:00:00 2001 From: Aldo Cortesi Date: Wed, 16 May 2012 18:24:32 +1200 Subject: Refuse to replay a request with missing content. --- test/test_flow.py | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'test') diff --git a/test/test_flow.py b/test/test_flow.py index d9933515..627d9cd0 100644 --- a/test/test_flow.py +++ b/test/test_flow.py @@ -516,6 +516,16 @@ class uFlowMaster(libpry.AutoTree): assert fm.load_script("nonexistent") assert "ValueError" in fm.load_script("scripts/starterr.py") + def test_replay(self): + s = flow.State() + fm = flow.FlowMaster(None, s) + f = tutils.tflow_full() + f.request.content = flow.CONTENT_MISSING + assert "missing" in fm.replay_request(f) + + f.intercepting = True + assert "intercepting" in fm.replay_request(f) + def test_script_reqerr(self): s = flow.State() fm = flow.FlowMaster(None, s) -- cgit v1.2.3