mirror of
https://github.com/certbot/certbot.git
synced 2026-08-03 00:22:04 +02:00
Add tox.cover.sh for proper coveralls experience.
This commit is contained in:
Executable
+21
@@ -0,0 +1,21 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
# This script is used by tox.ini (and thus Travis CI) in order to
|
||||||
|
# generate separate stats for each package. It should be removed once
|
||||||
|
# those packages are moved to separate repo.
|
||||||
|
|
||||||
|
cover () {
|
||||||
|
# "-c /dev/null" makes sure setup.cfg is not loaded (multiple
|
||||||
|
# --with-cover add up, --cover-erase must not be set for coveralls
|
||||||
|
# to get all the data); --with-cover scopes coverage to only
|
||||||
|
# specific package, positional argument scopes tests only to
|
||||||
|
# specific package directory
|
||||||
|
nosetests -c /dev/null --with-cover --cover-package "$1" \
|
||||||
|
--cover-min-percentage="$2" "$1"
|
||||||
|
}
|
||||||
|
|
||||||
|
# don't use sequential composition (;), if letsencrypt_nginx returns
|
||||||
|
# 0, coveralls submit will be triggered (c.f. .travis.yml,
|
||||||
|
# after_success)
|
||||||
|
cover letsencrypt 88 && cover acme 100 && \
|
||||||
|
cover letsencrypt_apache 67 && cover letsencrypt_nginx 90
|
||||||
@@ -23,10 +23,7 @@ setenv =
|
|||||||
basepython = python2.7
|
basepython = python2.7
|
||||||
commands =
|
commands =
|
||||||
pip install -e .[testing]
|
pip install -e .[testing]
|
||||||
nosetests --with-coverage --cover-min-percentage=68 letsencrypt
|
./tox.cover.sh
|
||||||
nosetests --with-coverage --cover-min-percentage=100 acme
|
|
||||||
nosetests --with-coverage --cover-min-percentage=57 letsencrypt_apache
|
|
||||||
nosetests --with-coverage --cover-min-percentage=58 letsencrypt_nginx
|
|
||||||
|
|
||||||
[testenv:lint]
|
[testenv:lint]
|
||||||
# recent versions of pylint do not support Python 2.6 (#97, #187)
|
# recent versions of pylint do not support Python 2.6 (#97, #187)
|
||||||
|
|||||||
Reference in New Issue
Block a user