Very simple check with stdout only
()
| 14 | |
| 15 | |
| 16 | def test_tee_simple(): |
| 17 | "Very simple check with stdout only" |
| 18 | chan = StringIO() |
| 19 | text = "Hello" |
| 20 | tee = Tee(chan, channel="stdout") |
| 21 | print(text, file=chan) |
| 22 | assert chan.getvalue() == text + "\n" |
| 23 | tee.close() |
| 24 | |
| 25 | |
| 26 | class TeeTestCase(unittest.TestCase): |