'Regression test: Check whether a test run with output to stderr
matches a previous run.'

def test_stderr_capture(self):

    class TestTest(unittest.TestCase, ):
        def test_foo(self):
            print('Foo    >    Bar', file=sys.stderr)
    self._try_test_run(TestTest, '<testsuite    errors="0"    failures="0"    name="unittest.suite.TestSuite"    tests="1"    time="0.000"><testcase    classname="test.test_xmlrunner.TestTest"    name="test_foo"    time="0.000"    /><system-out>&lt;![CDATA[\n\n]]&gt;</system-out><system-err>&lt;![CDATA[\nFoo    &gt;    Bar\n\n]]&gt;</system-err></testsuite>')
