language: cpp dist: trusty matrix: include: - os: linux env: PYTHON=2.7 - os: linux env: PYTHON=3.6 - os: linux env: CONDA=3.7 - os: linux env: CONDA=3.6 - os: osx env: PYTHON=2.7 - os: osx env: PYTHON=3.6 - os: osx env: CONDA=3.7 - os: osx env: CONDA=3.6 before_install: - | if [ "$TRAVIS_OS_NAME" = "linux" ]; then export CXX=g++-4.8 CC=gcc-4.8; fi if [ -n "$PYTHON" ]; then if [ "$TRAVIS_OS_NAME" = "osx" ]; then export PATH="/Users/travis/Library/Python/2.7/bin:$PATH" export MACOSX_DEPLOYMENT_TARGET="10.13" if [ "${PYTHON:0:1}" = "3" ]; then brew update; brew install python3; fi fi python -m pip install --user virtualenv virtualenv -p python${PYTHON:0:1} venv source venv/bin/activate elif [ -n "$CONDA" ]; then if [ "$TRAVIS_OS_NAME" = "linux" ]; then OS=Linux-x86_64; else OS=MacOSX-x86_64; fi wget -O miniconda.sh https://repo.continuum.io/miniconda/Miniconda${CONDA:0:1}-latest-$OS.sh bash miniconda.sh -b -p $HOME/miniconda export PATH="$HOME/miniconda/bin:$PATH" conda config --set always_yes yes --set changeps1 no conda config --add channels conda-forge conda update -q conda conda install -q conda-build conda create -q -n test-environment python=$CONDA source activate test-environment fi install: - | if [ -n "$PYTHON" ]; then python -m pip install . elif [ -n "$CONDA" ]; then conda build conda.recipe --python $CONDA conda install --use-local python_example fi script: - python tests/test.py