February 2022
Intermediate to advanced
274 pages
6h 28m
English
Parametrization techniques are quite effective at creating large numbers of test cases quickly. As such, it’s often beneficial to be able to run a subset of the tests. We first looked at -k in Running a Subset of Tests, but let’s use it here, as we’ve got quite a few test cases in this chapter:
| | $ pytest -v |
| | ========================= test session starts ========================== |
| | collected 16 items |
| | |
| | test_finish.py::test_finish_from_in_prog PASSED [ 6%] |
| | test_finish.py::test_finish_from_done PASSED [ 12%] |
| | test_finish.py::test_finish_from_todo PASSED [ 18%] |
| | test_finish_combined.py::test_finish PASSED [ 25%] |
| | test_fix_param.py::test_finish[done] PASSED [ 31%] |
| | test_fix_param.py::test_finish[in ... |
Read now
Unlock full access