Skip to content

Commit aa04f23

Browse files
committed
Trying to get coverage support
1 parent 82a9fb6 commit aa04f23

4 files changed

Lines changed: 10 additions & 6 deletions

File tree

.coveragerc

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
[run]
2+
source = core/
3+
dot/
4+

.travis.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ python:
44
- 3.5
55
- 3.6
66
install:
7+
- travis_retry pip install coverage coveralls
78
- travis_retry pip install -e ./core
89
- travis_retry pip install -e ./dot
910
script:
10-
- cd tests
11-
- python testrunner.py
11+
- coverage run tests/testrunner.py
1212
notifications:
1313
email: false
1414
after_success:

Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,10 @@ test-pre:
6767
reset
6868

6969
test: test-pre
70-
export PYTHONPATH=${PYTHONPATH} && cd ${TESTS_DIR} && python testrunner.py
70+
PYTHONPATH=${PYTHONPATH} python tests/testrunner.py
7171

7272
test3: test-pre
73-
export PYTHONPATH=${PYTHONPATH} && cd ${TESTS_DIR} && python3 testrunner.py
73+
PYTHONPATH=${PYTHONPATH} python3 tests/testrunner.py
7474

7575
tests: test
7676

tests/testrunner.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
# OTHER DEALINGS IN THE SOFTWARE.
2424

2525
import sys
26-
sys.path.append('..')
26+
sys.path.append('./tests')
2727
import pygraph
2828
import unittest
2929
import testlib
@@ -34,7 +34,7 @@
3434

3535
def test_modules():
3636
modlist = []
37-
for each in listdir('.'):
37+
for each in listdir('tests'):
3838
if (each[0:9] == "unittests" and each[-3:] == ".py"):
3939
modlist.append(each[0:-3])
4040
return modlist

0 commit comments

Comments
 (0)