'L{LoggingFile} can replace L{sys.stdout}.'

def test_print(self):

    f = self.observedFile()
    self.patch(sys, 'stdout', f)
    print('Hello,', end='    ')
    print('world.')
    self.assertEqual(f.messages, [u'Hello,    world.'])
