59 lines
2.2 KiB
YAML
59 lines
2.2 KiB
YAML
language: python
|
|
|
|
env:
|
|
- UNCERTAINTIES="N" PYTHON="2.6" NUMPY_VERSION=1.9.2
|
|
- UNCERTAINTIES="N" PYTHON="2.7" NUMPY_VERSION=1.11.2
|
|
- UNCERTAINTIES="N" PYTHON="3.3" NUMPY_VERSION=1.9.2
|
|
- UNCERTAINTIES="N" PYTHON="3.4" NUMPY_VERSION=1.11.2
|
|
- UNCERTAINTIES="N" PYTHON="3.5" NUMPY_VERSION=1.11.2
|
|
- UNCERTAINTIES="Y" PYTHON="3.5" NUMPY_VERSION=1.11.2
|
|
- UNCERTAINTIES="N" PYTHON="3.6" NUMPY_VERSION=1.11.2
|
|
- UNCERTAINTIES="N" PYTHON="2.7" NUMPY_VERSION=0
|
|
- UNCERTAINTIES="N" PYTHON="3.5" NUMPY_VERSION=0
|
|
|
|
branches:
|
|
only:
|
|
- staging
|
|
- trying
|
|
- master
|
|
|
|
before_install:
|
|
- sudo apt-get update
|
|
- if [[ "$PYTHON" == "2.7" ]]; then
|
|
wget https://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh -O miniconda.sh;
|
|
else
|
|
wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh;
|
|
fi
|
|
- bash miniconda.sh -b -p $HOME/miniconda
|
|
- export PATH="$HOME/miniconda/bin:$PATH"
|
|
- hash -r
|
|
- conda config --set always_yes yes --set changeps1 no
|
|
- conda update -q conda
|
|
# Useful for debugging any issues with conda
|
|
- conda info -a
|
|
|
|
# The next couple lines fix a crash with multiprocessing on Travis and are not specific to using Miniconda
|
|
- sudo rm -rf /dev/shm
|
|
- sudo ln -s /run/shm /dev/shm
|
|
|
|
- export ENV_NAME=travis
|
|
|
|
install:
|
|
- conda create --yes -n $ENV_NAME python=$PYTHON pip
|
|
- source activate $ENV_NAME
|
|
- if [ $PYTHON == '2.6' ]; then pip install unittest2; fi
|
|
- if [ $UNCERTAINTIES == 'Y' ]; then pip install 'uncertainties==2.4.7.1'; fi
|
|
- if [ $NUMPY_VERSION != '0' ]; then conda install --yes numpy==$NUMPY_VERSION; fi
|
|
- if [ $PYTHON == '3.2' ]; then pip install coverage==3.7.1; else pip install coverage; fi
|
|
- if [[ $TRAVIS_PYTHON_VERSION == '3.5' && $NUMPY_VERSION == 1.11.2 && $UNCERTAINTIES == "Y" ]]; then pip install babel serialize pyyaml; fi
|
|
- pip install coveralls
|
|
|
|
script:
|
|
- if [ $PYTHON == '2.6' ]; then coverage run -p --source=pint --omit="*test*","*compat*" setup.py test; fi
|
|
- if [ $PYTHON != '2.6' ]; then python -bb -m coverage run -p --source=pint --omit="*test*","*compat*" setup.py test; fi
|
|
- coverage combine
|
|
- coverage report -m
|
|
|
|
after_success:
|
|
- coveralls --verbose
|