Skip to content

Commit

Permalink
Merge branch 'branch-coverage'
Browse files Browse the repository at this point in the history
* branch-coverage:
  Remove one "no cover" pragma
  Configure coverage to use branch measurement
  Use pytest-cov for coverage collection
  • Loading branch information
suutari-ai committed Mar 11, 2017
2 parents 5d3c51f + 2ed0376 commit 9b12b8a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 2 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[run]
branch = True
2 changes: 1 addition & 1 deletion prequ/resolver.py
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ def __init__(self, constraints, repository, cache=None, prereleases=False, clear
self.their_constraints = set()
self.repository = repository
if cache is None:
cache = DependencyCache() # pragma: no cover
cache = DependencyCache()
self.dependency_cache = cache
self.prereleases = prereleases
self.clear_caches = clear_caches
Expand Down
6 changes: 2 additions & 4 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,13 @@ deps =
piplatest: pip
pip8: pip~=8.0
pip9: pip~=9.0
coverage
pytest
pytest-cov
pyyaml
commands =
pip --version
python -m coverage run --source prequ -m pytest \
py.test --cov=prequ --cov-config={toxinidir}/.coveragerc \
--strict --doctest-modules {posargs:tests/ prequ/}
python -m coverage report -m
python -m coverage html

[testenv:flake8]
basepython = python2.7
Expand Down

0 comments on commit 9b12b8a

Please sign in to comment.