Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

tweak documentation of report's sections attribute #8493

Merged
merged 1 commit into from Mar 26, 2021
Merged

Conversation

wimglenn
Copy link
Member

@wimglenn wimglenn commented Mar 26, 2021

fix some formatting in the TestReport / CollectReport, and reword the description about the 'sections' attribute

this is what it looks like currently: https://docs.pytest.org/en/stable/reference.html#pytest.reports.TestReport.sections

The CollectReport one maybe didn't render at all due to bunk formatting (?)

  • "which needs to marshallable" does not make a lot of sense (presumably means json serializable?) but is unnecessary anyway since the type is already annotated as List[Tuple[str, str]] which will be marshallable. Also I think I just now got the joke of why marshmallow project is named so... 😄
  • (str, str) just duplicated the existing type annotation so I changed it to (heading, content) to better indicate how each string in the pair is actually used
  • also mentioned that the sections is now also used for caplog

@nicoddemus
Copy link
Member

Thanks @wimglenn! It does look better. 👍

@nicoddemus nicoddemus merged commit 878a51e into main Mar 26, 2021
@nicoddemus nicoddemus deleted the docs-fix branch March 26, 2021 10:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants