-
Create virtual environment
python3 -m venv <venv_path>
Example:
python3 -m venv myenv
-
Activate virtual environment
source <venv_path>/bin/activate
Example:
source myenv/bin/activate
-
Deactivate virtual environment
deactivate
-
Run tests without warnings
pytest --disable-warnings
-
Run tests with fail fast
pytest -x
-
Run tests watching full differences
pytest -vv
-
Run tests with print function
pytest -s
-
Run tests of a file or directory
pytest <file_or_directory_path>
-
Run tests with many options
pytest -x -s -vv --disable-warnings