From 05d1b990435a61f27936fa44bcdc498941da1966 Mon Sep 17 00:00:00 2001 From: Aldo Cortesi Date: Thu, 19 Mar 2015 18:10:21 +1300 Subject: [PATCH] No output to stdout in the test suite, please. --- test/test_dump.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/test/test_dump.py b/test/test_dump.py index 11a024e38..48eeb244a 100644 --- a/test/test_dump.py +++ b/test/test_dump.py @@ -131,14 +131,16 @@ class TestDumpMaster: assert len(m.apps.apps) == 1 def test_replacements(self): + cs = StringIO() o = dump.Options(replacements=[(".*", "content", "foo")]) - m = dump.DumpMaster(None, o) + m = dump.DumpMaster(None, o, outfile=cs) f = self._cycle(m, "content") assert f.request.content == "foo" def test_setheader(self): + cs = StringIO() o = dump.Options(setheaders=[(".*", "one", "two")]) - m = dump.DumpMaster(None, o) + m = dump.DumpMaster(None, o, outfile=cs) f = self._cycle(m, "content") assert f.request.headers["one"] == ["two"] @@ -195,4 +197,3 @@ class TestDumpMaster: def test_stickyauth(self): self._dummy_cycle(1, None, "", stickyauth = ".*") -