summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorInada Naoki <songofacandy@gmail.com>2019-12-06 19:28:23 +0900
committerGitHub <noreply@github.com>2019-12-06 19:28:23 +0900
commit235c6036eabd89d5a28244091ac1e4f091b49679 (patch)
tree065497fe47445157ebe0ac00d0c9441b841ab842
parent7e9905bdfaecde83ddb1a4575e734a10b055fde9 (diff)
downloadmsgpack-python-235c6036eabd89d5a28244091ac1e4f091b49679.tar.gz
travis: Use codecov (#387)
-rw-r--r--.travis.yml48
1 files changed, 27 insertions, 21 deletions
diff --git a/.travis.yml b/.travis.yml
index 9d3ae74..378bc80 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -12,11 +12,20 @@ python:
- "3.7"
- "3.8-dev"
+
+_pure: &pure
+ install:
+ - pip install -U pip
+ - pip install -U pytest pytest-cov codecov
+ - pip install .
+ script:
+ - pytest --cov=msgpack -v test
+
matrix:
include:
- name: Black
language: python
- python: 3.8
+ python: 3.7
install:
- pip install black
script:
@@ -35,38 +44,35 @@ matrix:
- docker pull $DOCKER_IMAGE
script:
- docker run --rm -v `pwd`:/io -w /io $DOCKER_IMAGE /io/docker/runtests.sh
+
+ - name: "Python 2 (fallback)"
+ python: "2.7"
+ <<: *pure
+
- name: "pypy2.7"
python: "pypy2.7-7.1.1"
- install:
- - pip install -e .
- script:
- - py.test -v test
+ <<: *pure
+
- name: "pypy3"
python: "pypy3.6-7.1.1"
- install:
- - pip install -e .
- script:
- - pytest -v test
- - name: "Python 2 (fallback)"
- python: "2.7"
- install:
- - pip install -U pip
- - pip install -U pytest
- - pip install .
- script:
- - pytest -v test
+ <<: *pure
install:
- pip install -U pip
- - pip install -U pytest
- - pip install -r requirements.txt
+ - pip install -U pytest pytest-cov codecov
+ - pip install -r requirements.txt # Cython
- make cython
- pip install -e .
script:
- python -c 'import sys; print(hex(sys.maxsize))'
- python -c 'from msgpack import _cmsgpack'
- - pytest -v test
- - MSGPACK_PUREPYTHON=x pytest -v test
+ - pytest --cov=msgpack -v test
+ - MSGPACK_PUREPYTHON=x pytest --cov=msgpack -v test
+
+after_success:
+ - if [ -f .coverage ]; then
+ codecov;
+ fi
# vim: sw=2 ts=2