def test_retrieve_stdout(self): with retrieve_stdout() as sio: print("test") self.assertEqual(sio.getvalue(), "test\n")
def test_log(self): with retrieve_stdout() as sio: log("test") self.assertEqual(sio.getvalue(), " COALA - test\n")