From fcc97b251e8c64e9fa92c9e5d1a2e85f10c0740e Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Thu, 30 Mar 2017 06:51:27 -0400 Subject: Use new show_stderr flag so we can see errors printed to stderr during failing tests. --- tests/coveragetest.py | 3 +++ tests/test_plugins.py | 1 - 2 files changed, 3 insertions(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/coveragetest.py b/tests/coveragetest.py index 37e0937..28ee92e 100644 --- a/tests/coveragetest.py +++ b/tests/coveragetest.py @@ -72,6 +72,9 @@ class CoverageTest( # Tell newer unittest implementations to print long helpful messages. longMessage = True + # Let stderr go to stderr, pytest will capture it for us. + show_stderr = True + def setUp(self): super(CoverageTest, self).setUp() diff --git a/tests/test_plugins.py b/tests/test_plugins.py index 0edfebe..cb81229 100644 --- a/tests/test_plugins.py +++ b/tests/test_plugins.py @@ -558,7 +558,6 @@ class BadPluginTest(FileTracerTest): self.run_plugin(module_name) stderr = self.stderr() - print(stderr) # for diagnosing test failures. if our_error: errors = stderr.count("# Oh noes!") -- cgit v1.2.1