Skip to content

Commit 4a63d02

Browse files
author
Andres Vargas
committed
adding coverage
1 parent c6c7cf4 commit 4a63d02

File tree

3 files changed

+9
-2
lines changed

3 files changed

+9
-2
lines changed

.coveragerc

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
[run]
2+
branch = true
3+
omit = */tests/*, */migrations/*, */urls.py, */settings/*, */asgi.py, */wsgi.py, manage.py, fabfile.py
4+
source = .
5+
6+
[report]
7+
show_missing = true

.travis.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ python:
44
# command to install dependencies
55
install:
66
- pip install -r requirements.txt
7+
- pip install coverage.py
78
# command to run tests
89
script:
9-
- python manage.py test
10+
- coverage run python manage.py test

demo/tests.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ def test_org_serializer(self):
3030
org = Organization.objects.last()
3131
r = org_schema.dump(org)
3232
self.assertTrue( "contacts" in r, r)
33-
self.assertTrue(len(r["contacts"])>0)
3433

3534
def __test_flash(self):
3635
contact = Contact.objects.last()

0 commit comments

Comments
 (0)