coverage script

This commit is contained in:
Élie Bouttier 2016-07-05 23:25:20 +02:00
parent 6039905d3b
commit 1cdc24107a
2 changed files with 14 additions and 0 deletions

2
.gitignore vendored
View File

@ -1,5 +1,7 @@
/venv/
/src/
/.coverage
/htmlcov/
*.pyc
*.swp
*.sqlite3

12
coverage.sh Executable file
View File

@ -0,0 +1,12 @@
#!/bin/bash
. venv/bin/activate
which coverage >/dev/null 2>&1
if [ "$?" -ne 0 ]; then
pip install coverage
fi
coverage run --branch --source=accounts,ponyconf,proposals,conversations --omit=*/migrations/*,*/apps.py,ponyconf/wsgi.py manage.py test
coverage html
xdg-open htmlcov/index.html