Pytest Logging: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
No edit summary
Line 4: Line 4:
=Internal=
=Internal=
* [[Pytest#Subjects|Pytest]]
* [[Pytest#Subjects|Pytest]]
=Overview=
<code>pytest</code> captures the <font color=darkkhaki>stdout and stderr</font> generated while running the tests, and that is why they cannot be seen in the running terminal. To disable this behavior and allow <font color=darkkhaki>stdout and stderr</font>  propagation, start <code>pytest</code> with:
<font size=-1>
pytest -s|--capture=no ...
</font>

Revision as of 01:26, 17 February 2022

External

Internal

Overview

pytest captures the stdout and stderr generated while running the tests, and that is why they cannot be seen in the running terminal. To disable this behavior and allow stdout and stderr propagation, start pytest with:

pytest -s|--capture=no ...