Skip to content

Commit

Permalink
coverage: add coveralls coverage testing
Browse files Browse the repository at this point in the history
Using coveralls.io to give coverage data for toolkit.
  • Loading branch information
dwaynebailey committed Feb 20, 2014
1 parent fe63343 commit 0509dbf
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 2 deletions.
9 changes: 9 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[run]
omit =
tests/*
translate/test_*
translate/*/test_*
translate/*/*/test_*
translate/misc/diff_match_patch.py
translate/misc/selector.py
translate/misc/wsgiserver/*
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,6 @@ tests/xliff_conformance/af-pootle.xlf

# Requirements generation
.reqs

# Coverage
.coverage*
7 changes: 5 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ matrix:
before_install:
- sudo apt-get install python-aeidon
install:
- pip install coveralls
- if [[ $MINVERSION ]]; then rm min-required.txt; make min-required.txt; pip install -r min-required.txt; pip install --upgrade pytest; fi
- if [[ ! $MINVERSION ]]; then pip install -r requirements/dev.txt; fi
- if [[ $TRAVIS_PYTHON_VERSION == 'pypy' ]]; then pip install --upgrade --pre lxml; fi
Expand All @@ -30,10 +31,12 @@ script:
# Compile all the files
- python -m compileall -q -f .
- python setup.py --quiet build
- py.test --boxed -r EfsxX
- py.test --boxed --cov=. -r EfsxX
- ./tools/pep8.sh travis
# -W report warnings as errors when building docs
- cd docs; make SPHINXOPTS=-W html
- cd docs; make SPHINXOPTS=-W html; cd ..
after_success:
coveralls
notifications:
email:
on_failure: always
Expand Down
3 changes: 3 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ Translate Toolkit
.. image:: https://travis-ci.org/translate/translate.png
:alt: Build Status
:target: https://travis-ci.org/translate/translate
.. image:: https://coveralls.io/repos/translate/translate/badge.png?branch=master
:alt: Coverage Status
:target: https://coveralls.io/r/translate/translate?branch=master

The Translate Toolkit is a set of software and documentation designed to help
make the lives of localizers both more productive and less frustrating.
Expand Down
1 change: 1 addition & 0 deletions requirements/dev.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
-r optional.txt

pytest>=2.2
pytest-cov
pytest-xdist
Sphinx>=1.2.0
pep8
Expand Down

0 comments on commit 0509dbf

Please sign in to comment.