From 4f02480482cec13d36ed9b216784c3136e047192 Mon Sep 17 00:00:00 2001 From: Aldo Cortesi Date: Sun, 6 Mar 2011 14:48:16 +1300 Subject: [PATCH] Allow client replays to be replayed against server replays. Useful for testing. --- libmproxy/flow.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libmproxy/flow.py b/libmproxy/flow.py index 559766108..5f1e7871e 100644 --- a/libmproxy/flow.py +++ b/libmproxy/flow.py @@ -54,10 +54,12 @@ class ClientPlaybackState: if self.flows and not self.current: n = self.flows.pop(0) self.current = master.handle_request(n.request) - if not testing: + if not testing and not self.current.response: #begin nocover master.state.replay_request(self.current, master.masterq) #end nocover + elif self.current.response: + master.handle_response(self.current.response) class ServerPlaybackState: