Skip to content

Commit

Permalink
Add test coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
BorjaEst committed Nov 30, 2020
1 parent a479c25 commit 020939e
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 0 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ htmlcov/
.cache
nosetests.xml
coverage.xml
cover/
*.cover
*.py,cover
.hypothesis/
Expand Down
18 changes: 18 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,24 @@ commands =
{[testenv]commands}
stestr -v run {posargs}

[testenv:cover]
# TODO(stephenfin): Remove the PYTHON hack below in favour of a [coverage]
# section once we rely on coverage 4.3+
#
# https://bitbucket.org/ned/coveragepy/issues/519/
envdir = {toxworkdir}/shared
setenv =
{[testenv]setenv}
PYTHON=coverage run --source eosc_perf --parallel-mode
commands =
{[testenv]commands}
coverage erase
stestr -v run {posargs}
coverage combine
coverage html -d cover
coverage xml -o cover/coverage.xml
coverage report

[testenv:pep8]
envdir = {toxworkdir}/shared
commands = - flake8 --format=pylint --output-file=flake8.log
Expand Down

0 comments on commit 020939e

Please sign in to comment.