Skip to content

Commit

Permalink
update testing matrix, add coverage report
Browse files Browse the repository at this point in the history
  • Loading branch information
davidism committed Sep 26, 2017
1 parent f93c737 commit e91bb0e
Show file tree
Hide file tree
Showing 6 changed files with 87 additions and 22 deletions.
5 changes: 5 additions & 0 deletions .codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
comment: off
coverage:
status:
project: off
patch: off
11 changes: 11 additions & 0 deletions .coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
[run]
branch = True
source =
flask_sqlalchemy
tests

[paths]
source =
flask_sqlalchemy
.tox/*/lib/python*/site-packages/flask_sqlalchemy
.tox/pypy/site-packages/flask_sqlalchemy
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,6 @@ docs/_build
*.egg
.idea/
.cache/
htmlcov
.coverage
.coverage.*
42 changes: 29 additions & 13 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,24 +1,40 @@
sudo: false
language: python

python:
- "2.6"
- "2.7"
- "pypy"
- "3.3"
- "3.4"
- "3.5"
- "3.6-dev"

env:
- REQUIREMENTS=lowest
- REQUIREMENTS=current
matrix:
include:
- python: 3.6
env: TOXENV=py,codecov
- python: 3.5
env: TOXENV=py,codecov
- python: 3.4
env: TOXENV=py,codecov
- python: 3.3
env: TOXENV=py,py-lowest,codecov
- python: 2.7
env: TOXENV=py,py,codecov
- python: 2.6
env: TOXENV=py,py-lowest,codecov
- python: pypy
env: TOXENV=py,codecov
- python: nightly
env: TOXENV=py,codecov
- python: 3.6
env: TOXENV=docs_html

install:
- pip install tox

script:
- tox -e py-$REQUIREMENTS
- tox

cache:
- pip

branches:
only:
- master
- /^.*-maintenance$/

notifications:
email: false
Expand Down
3 changes: 2 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ tag_date = 1
release = egg_info -Db ''

[tool:pytest]
norecursedirs = .* _* scripts {args}
minversion = 3.0
testpaths = tests

[bdist_wheel]
universal = 1
Expand Down
45 changes: 37 additions & 8 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,16 +1,45 @@
[tox]
envlist = {py26,py27,pypy,py33,py34,py35,py36}-{lowest,current}
envlist =
py{36,35,34,33,27,26,py}
py{36,33,27,26,py}-lowest
docs_html
coverage_report

[testenv]
commands = py.test {posargs}

deps =
pytest
pytest>=3
coverage
blinker

lowest: flask==0.10
lowest: sqlalchemy==0.8
lowest: blinker==1.0

current: flask
current: sqlalchemy
current: blinker
commands =
coverage run -p -m pytest

[testenv:docs_html]
deps = sphinx
commands = sphinx-build -W -b html -d {envtmpdir}/doctrees docs docs/_build/html

[testenv:docs_linkcheck]
deps = sphinx
commands = sphinx-build -W -b linkcheck -d {envtmpdir}/doctrees docs docs/_build/linkcheck

[testenv:coverage_report]
deps = coverage
skip_install = true
commands =
coverage combine
coverage report
coverage html

[testenv:codecov]
passenv = CI TRAVIS TRAVIS_*
deps =
codecov
skip_install = true
commands =
python -c 'import sys, pip; sys.version_info < (2, 7) and pip.main(["install", "argparse", "-q"])'
coverage combine
coverage report
codecov

0 comments on commit e91bb0e

Please sign in to comment.