When working with Pytest, it is tempting to keep re-using the same old commands. However, there are some really useful options you can pass in via the command line in order to change the set of tests being run and most likely speed up your workflow.
Take for example, your basic pytest command as a base:
pytest "project/tests"The above command is running Pytest out of the 'project/tests' folder.
Here are some useful variations to try for running tests:
pytest "project/tests" -p no:warningsusers pytest "project/tests" --lfpytest "project/tests" -lpytest "project/tests" -xpytest "project/tests" --maxfail=2pytest "project/tests" -p no:warnings --cov="project"pytest "project/tests" -p no:warnings --cov="project" --cov-report htmlpytest "project/tests" -k registrationpytest "project/tests" --durations=2Hopefully some of these will help streamline your Pytest-ing workflows!