test capture_output(stdout=False)
()
| 125 | yield nt.assert_equal, hello_stderr, cap.stderr |
| 126 | |
| 127 | def test_capture_output_no_stdout(): |
| 128 | """test capture_output(stdout=False)""" |
| 129 | rich = capture.RichOutput(data=full_data) |
| 130 | with capture.capture_output(stdout=False) as cap: |
| 131 | print(hello_stdout, end="") |
| 132 | print(hello_stderr, end="", file=sys.stderr) |
| 133 | rich.display() |
| 134 | yield nt.assert_equal, "", cap.stdout |
| 135 | yield nt.assert_equal, hello_stderr, cap.stderr |
| 136 | yield nt.assert_equal, len(cap.outputs), 1 |
| 137 | |
| 138 | def test_capture_output_no_stderr(): |
| 139 | """test capture_output(stderr=False)""" |