Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make Travis run tests on OSX. #771

Merged
merged 1 commit into from
Mar 16, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 19 additions & 17 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@ branches:
- master
- develop

language: python
os:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

maybe this line is needed?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Python + OSX will break Travis CI.
As we use miniconda, it's fine to skip the language.

Maybe the reason is that I have tested this patch with my repo?

- linux
- osx
env:
global:
- secure: "HIj3p+p2PV8DBVg/KGUx6n83KwB0ASE5FwOn0SMB9zxnzAqe8sapwdBQdMdq0sXB7xT1spJqRxuxOMVEVn35BNLu7bxMLfa4287C8YXcomnvmv9xruxAsjsIewnNQ80vtPVbQddBPxa4jKbqgPby5QhhAP8KANAqYe44pIV70fY="
Expand All @@ -13,29 +15,29 @@ env:
- GIT_CI_USER: TravisCI
- GIT_CI_EMAIL: [email protected]
- MDA_DOCDIR: package/doc/html
matrix:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Or maybe declaring matrix twice breaks it?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah that is a very good chance. I'm not aware of duplicate keys in the YAML standard.

- SETUP=minimal PYTHON_VERSION=2.7
- SETUP=full PYTHON_VERSION=2.7
- SETUP=minimal PYTHON_VERSION=3.3
- SETUP=full PYTHON_VERSION=3.3
matrix:
allow_failures:
- python: "3.3"
env: SETUP=full
include:
- python: "2.7"
env: SETUP=minimal
- python: "2.7"
env: SETUP=full
- python: "3.3"
env: SETUP=full
- env: SETUP=minimal PYTHON_VERSION=3.3
- env: SETUP=full PYTHON_VERSION=3.3

before_install:
- wget http://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh -O miniconda.sh
- if [[ $TRAVIS_OS_NAME == 'osx' ]]; then wget http://repo.continuum.io/miniconda/Miniconda-latest-MacOSX-x86_64.sh -O miniconda.sh; fi
- if [[ $TRAVIS_OS_NAME == 'linux' ]]; then wget http://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh -O miniconda.sh; fi
- chmod +x miniconda.sh
- ./miniconda.sh -b -p /home/travis/miniconda
- export PATH=/home/travis/miniconda/bin:$PATH
- ./miniconda.sh -b -p $(pwd)/miniconda
- export PATH=$(pwd)/miniconda/bin:$PATH
- conda update --yes conda
install:
- if [[ $SETUP == 'full' ]]; then conda create --yes -q -n pyenv python=2.7 numpy scipy nose=1.3.7 sphinx=1.3; fi
- if [[ $SETUP == 'minimal' ]]; then conda create --yes -q -n pyenv python=2.7 numpy nose=1.3.7 sphinx=1.3; fi
- if [[ $SETUP == 'full' ]]; then conda create --yes -q -n pyenv python=$PYTHON_VERSION numpy scipy nose=1.3.7 sphinx=1.3; fi
- if [[ $SETUP == 'minimal' ]]; then conda create --yes -q -n pyenv python=$PYTHON_VERSION numpy nose=1.3.7 sphinx=1.3; fi
- source activate pyenv
- if [[ $SETUP == 'full' ]]; then conda install --yes python=$TRAVIS_PYTHON_VERSION cython biopython matplotlib networkx netcdf4; fi
- if [[ $SETUP == 'minimal' ]]; then conda install --yes python=$TRAVIS_PYTHON_VERSION cython biopython networkx; fi
- if [[ $SETUP == 'full' ]]; then conda install --yes python=$PYTHON_VERSION cython biopython matplotlib networkx netcdf4; fi
- if [[ $SETUP == 'minimal' ]]; then conda install --yes python=$PYTHON_VERSION cython biopython networkx; fi
# ensure that cython files are rebuilt
- find . -name '*.pyx' -exec touch '{}' \;
- pip install -v package/
Expand Down