Move coverage configuration to .coverage
Introduce a .coveragerc file to omit multiple files from test coverage such as django's migrations, env and the tests itself.
This commit is contained in:
parent
6b901ca5c2
commit
2ddb51512b
8
.coveragerc
Normal file
8
.coveragerc
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
# .coveragerc to control coverage.py
|
||||||
|
|
||||||
|
[run]
|
||||||
|
omit =
|
||||||
|
**/migrations/*.py
|
||||||
|
**/tests.py
|
||||||
|
env*
|
||||||
|
/home/travis/virtualenv*
|
@ -5,7 +5,7 @@ install: "pip install -r requirements.txt && pip install coveralls"
|
|||||||
|
|
||||||
script:
|
script:
|
||||||
- python manage.py collectstatic --noinput
|
- python manage.py collectstatic --noinput
|
||||||
- coverage run --omit='env*' --source='.' manage.py test
|
- coverage run --rcfile .coveragerc manage.py test
|
||||||
|
|
||||||
after_success:
|
after_success:
|
||||||
- coveralls
|
- coveralls
|
||||||
|
Loading…
Reference in New Issue
Block a user