Include TerminalReporter in reference docs #6649#12661
Include TerminalReporter in reference docs #6649#12661nicoddemus merged 6 commits intopytest-dev:mainfrom
Conversation
d020e1b to
e3a6c63
Compare
|
I'm wondering if I should/can add an import of TerminalReporter somewhere around Lines 70 to 72 in 6c806b4 |
There was a problem hiding this comment.
Hi @soxofaan, thanks for the PR.
The TerminalReporter not being part of the docs is an oversight, given they are part of the signature of pytest_terminal_summary.
I'm wondering if I should/can add an import of TerminalReporter somewhere around
Yes we should also publish it as part of the public API: if it is used by a public hook, it should also be available from the pytest namespace.
Also the build failed with:
/home/docs/checkouts/readthedocs.org/user_builds/pytest/envs/12661/lib/python3.12/site-packages/_pytest/terminal.py:docstring of _pytest.terminal.TerminalReporter.build_summary_stats_line:11: WARNING: Definition list ends without a blank line; unexpected unindent.
Probably just need to fix the docstring here:
pytest/src/_pytest/terminal.py
Lines 1342 to 1343 in 6c806b4
To:
This function builds a list of the "parts" that make up for the text in that line, in
- the example above it would be:
+ the example above it would be::It is unfortunate that the entire terminal plugin is being passed along to this hook, but too late for this now so we might as well document it.
|
In stoll hoping we can replace it, It's api is from python 2.4 times and libraries more dedicated to the topic recently showed a much nicer variant (like rich) |
|
thanks for the feedback. All tests pass now |
I know, let's hope we manage to eventually find the time (and will) to do that. 🤞 |
|
This while small should not be backported, as it is introducing a new public symbol, so it should happen in the next minor release. |
|
@RonnyPfannschmidt |
|
(I have a local fix for the docs, will push shortly) |
Closes #6649
closes #XYZWto the PR description and/or commits (whereXYZWis the issue number). See the github docs for more information.changelogfolder, with a name like<ISSUE NUMBER>.<TYPE>.rst. See changelog/README.rst for details.AUTHORSin alphabetical order.