Assertions
Assertion is a way to test the observed results with the expected ones
Last updated
Assertion is a way to test the observed results with the expected ones
Last updated
details for the failed assertions
passed assertions (may not be for everyone)
number of assertions done on a test suite/scenario
Number of Assertions passed/failed in a test suite/case
Expected Part of the Assertion and Observed Part of the Assertion
Details of the Failed Assertion (include stack trace)
To save the details of the assertions passed in pytest, please add the enable_assertion_pass_hook as true in your pytest.ini file
Please add this in pytest.ini
and this would add details for passed assertions
Reference from pytest docs.
Following are the features/ways pytest provides to process assertions and how handshakes report it in db/excel
Recommended way to write this case:
If the test passes, refer to the 'description' of the test. If it fails, the details can be found in both the description and the error field of the test case or suite. These are easily identifiable through the generated reports.
Currently, I have not observed pytest to send the details of the passed assertion, when the expected exception was raised inside the test case.