'Test that the reporter safely writes to its stream.'

def test_brokenStream(self):

    result = self.resultFactory(stream=BrokenStream(self.stream))
    result._writeln('Hello')
    self.assertEqual(self.stream.getvalue(), 'Hello\n')
    self.stream.truncate(0)
    self.stream.seek(0)
    result._writeln('Hello    %s!', 'World')
    self.assertEqual(self.stream.getvalue(), 'Hello    World!\n')
