pytest
pytest copied to clipboard
The order in which test results are presented is uncontrollable
What's the problem this feature will solve?
如图所示, 添加了
@pytest.hookspec
def pytest_terminal_summary(terminalreporter):
方法之后,报告偶发就会跑到 ========xxx====== 线下面,没办法固定位置。能否有方法可以固定相对位置。(黄色日志)
Describe the solution you'd like
Alternative Solutions
Additional context
It's not clear what you are asking for
s
As shown in the figure, is there any way to have the log section displayed above the arrow
During the process, I found that the order of execution was out of order, and I wanted to make sure that the log (the yellow part) was always one piece and not divided by the white result line.
Are you running this in PyCharm? I noticed this happening on occasion as well.
Given it works as expected on the command-line, seems like an issue on how PyCharm handles the stdout/stderr buffers.