(self)
| 57 | return "\n".join(redact(r.getMessage()) for r in cm.records) |
| 58 | |
| 59 | def test_stdout(self) -> None: |
| 60 | with self.assertLogs(level=logging.DEBUG) as cm: |
| 61 | self.emit(out(r"arf\n")) |
| 62 | self.assertExpectedInline( |
| 63 | self.flog(cm), |
| 64 | """\ |
| 65 | $ python emitter.py o 'arf\\n' |
| 66 | arf |
| 67 | """, |
| 68 | ) |
| 69 | |
| 70 | def test_stderr(self) -> None: |
| 71 | with self.assertLogs(level=logging.DEBUG) as cm: |