You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
λ python .tmp\test-ut-skip.py
sss
----------------------------------------------------------------------
Ran 1 test in 0.000s
OK (skipped=3)
Running with pytest:
λ pytest .tmp\test-ut-skip.py -q
ss [100%]
2 skipped in 0.01 seconds
The problem is that TestCaseFunction.addSkip will append the exception info to a list, but pytest_runtest_makereport will only pop one item off the list. We need to find a way to hook into TestCase.subTest to issue pytest_runtest_logreport from within the with statement.
The text was updated successfully, but these errors were encountered:
I was wondering why pytest did not report a failure for step i=5 at all. It does report a failure if both skipTests are changed to pass, but seemingly the presence of skipTest throws this off.
This is significantly worse than just failing to report the right number of skipped tests. A failing run is erroneously handled as a passing run.
Given this test case:
Running with
python
:Running with
pytest
:The problem is that
TestCaseFunction.addSkip
will append the exception info to a list, butpytest_runtest_makereport
will only pop one item off the list. We need to find a way to hook intoTestCase.subTest
to issuepytest_runtest_logreport
from within thewith
statement.The text was updated successfully, but these errors were encountered: