- Create virtual environment:
python -m venv .venv --prompt pytest-tutorial
- Activate the virtual environment:
source .venv/bin/activate
- Install the tutorial module:
pip install -e .
- Install other dependencies:
pip install -r requirements.txt
- Run the tests
pytest -v -s
Take a look through tests/test_mocks.py
for various ways on using python mocks and patching to test things.