travis experiment #12

This commit is contained in:
Manuel Barkhau 2018-09-05 21:54:34 +02:00
parent 44a039bc11
commit 3e3f7ab56e
4 changed files with 28 additions and 19 deletions

View file

@ -1,22 +1,26 @@
os: linux os: linux
dist: xenial
sudo: true
language: python language: python
cache: pip cache: pip
python:
- "3.7"
- "3.6"
- "3.5"
- "pypy3.5"
- "2.7"
- "pypy2.7"
before_install: before_install:
- uname
- sudo apt-get install -y git mercurial - sudo apt-get install -y git mercurial
- sudo bash travis_build_wheel.sh - sudo bash travis_build_wheel.sh
script: script:
- python --version - python --version
- bash travis_run_tests.sh - bash travis_run_tests.sh
matrix:
include:
- python: "3.6"
- python: "3.5"
- python: "3.4"
- python: "2.7"
- python: "pypy3.5"
- python: "pypy2.7"
- python: "3.7"
dist: xenial
sudo: true

View file

@ -68,6 +68,7 @@ setuptools.setup(
"Operating System :: MacOS :: MacOS X", "Operating System :: MacOS :: MacOS X",
"Programming Language :: Python", "Programming Language :: Python",
"Programming Language :: Python :: 2.7", "Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3.4",
"Programming Language :: Python :: 3.5", "Programming Language :: Python :: 3.5",
"Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.7",

View file

@ -1,14 +1,18 @@
#!/bin/bash #!/bin/bash
set -e set -e
if [[ $(which python3.7) ]]; then if [[ $(which python3.6) ]]; then
python3.7 --version python3.6 --version
else else
curl -sSf -o python-3.7.tar.bz2 https://s3.amazonaws.com/travis-python-archives/binaries/ubuntu/16.04/x86_64/python-3.7.tar.bz2 if [[ $(uname) ]]; then
tar xjf python-3.7.tar.bz2 --directory / curl -sSf -o python-3.6.tar.bz2 https://s3.amazonaws.com/travis-python-archives/binaries/ubuntu/14.04/x86_64/python-3.6.tar.bz2
source $HOME/virtualenv/python3.7.0/bin/activate else
curl -sSf -o python-3.6.tar.bz2 https://s3.amazonaws.com/travis-python-archives/binaries/ubuntu/14.04/x86_64/python-3.6.tar.bz2
fi
tar xjf python-3.6.tar.bz2 --directory /
source $HOME/virtualenv/python3.6.0/bin/activate
fi fi
python3.7 --version python3.6 --version
python3.7 -m pip install setuptools lib3to6 python3.6 -m pip install setuptools lib3to6
python3.7 setup.py bdist_wheel --python-tag=py2.py3 python3.6 setup.py bdist_wheel --python-tag=py2.py3

View file

@ -13,7 +13,7 @@ python -m pip install $(ls -1t dist/pycalver*.whl | head -n 1)
grep 'coding: utf-8' $(python -c 'import pycalver;print(pycalver.__file__.replace(".pyc", ".py"))') grep 'coding: utf-8' $(python -c 'import pycalver;print(pycalver.__file__.replace(".pyc", ".py"))')
python -m pytest test/ python -m pytest test/
if [[ $(python -c "import sys;print(sys.version[:3])") == "3.7" ]]; then if [[ $(python -c "import sys;sys.exit(sys.version[:3] < '3.6')") ]]; then
python -m pip install $(cat requirements-test.txt) python -m pip install $(cat requirements-test.txt)
python -m flake8 src/pycalver/ python -m flake8 src/pycalver/