-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
Clarify pytest_assertrepr_compare in Docs #4759
Copy link
Copy link
Closed
Labels
good first issueeasy issue that is friendly to new contributoreasy issue that is friendly to new contributortype: docsdocumentation improvement, missing or needing clarificationdocumentation improvement, missing or needing clarification
Metadata
Metadata
Assignees
Labels
good first issueeasy issue that is friendly to new contributoreasy issue that is friendly to new contributortype: docsdocumentation improvement, missing or needing clarificationdocumentation improvement, missing or needing clarification
Type
Fields
Give feedbackNo fields configured for issues without a type.
I think the documentation on the assert page for "Defining your own assertion comparison" could be clarified.
pytest/doc/en/assert.rst
Lines 208 to 212 in 7dcd9bf
As is I interpret it as addressing how to control how two elements are compared in an assert statement. I also received an answer to a question on Stack Overflow that suggested someone else interpreted this way so I figured I'd suggest making a change.
I think changing the title to something like "Defining your own explanation for failed assertions" would make things clearer and is more in line with the docstring for
pytest_assertrepr_compare.