Add support for travis and coveralls.
This works by running tox inside travis, rather than duplicating the tox config in travis syntax. The big win here is that coverage collects across all the Python versions and then submits the combined result to coveralls.
This commit is contained in:
20
.coveragerc
Normal file
20
.coveragerc
Normal file
@@ -0,0 +1,20 @@
|
||||
[run]
|
||||
|
||||
# Measure coverage of both tests and wrapt module.
|
||||
source =
|
||||
tests
|
||||
wrapt
|
||||
|
||||
# This doesn't run the tests in parallel, it just causes the output to land
|
||||
# in uniquely-named .coverage.* files to be combined at the end of running
|
||||
# tox over the matrix.
|
||||
parallel = true
|
||||
|
||||
[paths]
|
||||
|
||||
# For the coverage combine command, consider these paths equivalent with
|
||||
# the first one being primary.
|
||||
src =
|
||||
src/
|
||||
.tox/*/lib/*/site-packages/
|
||||
.tox/pypy*/site-packages/
|
13
.travis.yml
Normal file
13
.travis.yml
Normal file
@@ -0,0 +1,13 @@
|
||||
language: python
|
||||
python: 2.7
|
||||
env:
|
||||
global:
|
||||
- COVERAGE_CMD="coverage run -m"
|
||||
- COVERAGE_DEP=coverage
|
||||
install:
|
||||
- pip install tox coveralls
|
||||
script:
|
||||
- tox
|
||||
after_script:
|
||||
- coverage combine
|
||||
- coveralls
|
Reference in New Issue
Block a user