diff options
author | Angel Velásquez <angvp@archlinux.org> | 2017-05-18 03:12:06 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-05-18 03:12:06 -0400 |
commit | 1afe9133f1e221654cba90c252246734a23379bc (patch) | |
tree | e3366246d56b69a7599aea306c05cc2116c4432d | |
parent | a9dcbbd1aa69e06e8373a7f0836fbc8a12d54b86 (diff) | |
parent | 5922d9321a10bdf32c46b543ae13008faec2ae76 (diff) | |
download | archweb-1afe9133f1e221654cba90c252246734a23379bc.tar.gz archweb-1afe9133f1e221654cba90c252246734a23379bc.zip |
Merge pull request #17 from jelly/coverage
README: describe running unit tests / coverage
-rw-r--r-- | .travis.yml | 7 | ||||
-rw-r--r-- | README.md | 14 |
2 files changed, 19 insertions, 2 deletions
diff --git a/.travis.yml b/.travis.yml index 81cef987..4757641f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,11 @@ language: python python: - "2.7" -install: "pip install -r requirements.txt" +install: "pip install -r requirements.txt && pip install coveralls" script: - python manage.py collectstatic --noinput - - python manage.py test + - coverage run --omit='env*' --source='.' manage.py test + +after_success: + - coveralls @@ -85,6 +85,20 @@ required. A simple debugging SMTP server can be setup using Python. In local_settings.py change the EMAIL_HOST to 'localhost' and the EMAIL_PORT to 1025. +# Running tests and coverage + +To the unittests execute the following commands: + + ./manage.py collectstatic --noinput + ./manage.py test + +Running coverage: + + pip install coverage + coverage run --omit='env*' --source='.' manage.py test + coverage report + + # Production Installation Ask someone who knows, or you are going to be in trouble. |