Skip to content

Commit

Permalink
Add fast way to run coverage locally.
Browse files Browse the repository at this point in the history
  • Loading branch information
mblayman committed Nov 14, 2021
1 parent 473835e commit 881e417
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
8 changes: 8 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,14 @@ graph:
coverage:
pytest --cov=homeschool --migrations -n 2 --dist loadfile

# fcof == "fast coverage" by skipping migrations checking. Save that for CI.
# -n 8 --dist loadfile, 8 CPUs, 515 tests, 20s
# -n 4 --dist loadfile, 4 CPUs, 515 tests, 13s
# -n 2 --dist loadfile, 4 CPUs, 515 tests, 15s
fcov:
@echo "Running fast coverage check"
@pytest --cov=homeschool -n 4 --dist loadfile -q

mypy:
mypy homeschool project manage.py

Expand Down
1 change: 1 addition & 0 deletions requirements-dev.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ mypy==0.910
pip-tools
pre-commit
pygraphviz==1.7
pytest==6.2.5
pytest-cov==3.0.0
pytest-django==4.4.0
pytest-xdist==2.4.0
Expand Down

0 comments on commit 881e417

Please sign in to comment.