
# Iris setup credit to github.com/SciTools/iris 07bbaf4.
#

language: python
python:
  - 2.7.12
sudo: false

git:
  depth: 10000

install:
  # Install miniconda
  # -----------------
  - export CONDA_BASE=https://repo.continuum.io/miniconda/Miniconda
  - wget ${CONDA_BASE}2-latest-Linux-x86_64.sh -O miniconda.sh;
  - bash miniconda.sh -b -p $HOME/miniconda
  - export PATH="$HOME/miniconda/bin:$PATH"

  # Create the basic testing environment
  # ------------------------------------
  # Explicitly add defaults channel, see https://github.com/conda/conda/issues/2675
  - conda config --add channels defaults
  - conda config --set always_yes yes --set changeps1 no
  - conda config --set show_channel_urls True
  - conda update --quiet conda
  - ENV_NAME='test-environment'
  - conda create --quiet -n $ENV_NAME python=$TRAVIS_PYTHON_VERSION
  - source activate $ENV_NAME

  # Download Iris 1.13 and all dependencies.
  - conda install -c conda-forge iris=1.13
  - conda install -c conda-forge iris-grib=0.10.1

  # Install our own extra dependencies (+ filelock for Iris test).
  - conda install -c conda-forge mock filelock numpy=1.13.3 pycodestyle pylint pandas python-stratify sphinx=1.7.0

script:
  - python -c "import iris"
  - bin/improver tests


# Iris setup credit to github.com/SciTools/iris 07bbaf4.
#

language: python
python:
  - 2.7.12
sudo: false

git:
  depth: 10000

install:
  # Install miniconda
  # -----------------
  - export CONDA_BASE=https://repo.continuum.io/miniconda/Miniconda
  - wget ${CONDA_BASE}2-latest-Linux-x86_64.sh -O miniconda.sh;
  - bash miniconda.sh -b -p $HOME/miniconda
  - export PATH="$HOME/miniconda/bin:$PATH"

  # Create the basic testing environment
  # ------------------------------------
  # Explicitly add defaults channel, see https://github.com/conda/conda/issues/2675
  - conda config --add channels defaults
  - conda config --set always_yes yes --set changeps1 no
  - conda config --set show_channel_urls True
  - conda update --quiet conda
  - ENV_NAME='test-environment'
  - conda create --quiet -n $ENV_NAME python=$TRAVIS_PYTHON_VERSION
  - source activate $ENV_NAME

  # Download Iris 1.13 and all dependencies.
  - conda install -c conda-forge iris=2.0

  # Install our own extra dependencies (+ filelock for Iris test).
  - conda install -c conda-forge mock filelock numpy=1.13.3 pycodestyle pylint pandas python-stratify sphinx=1.7.0

script:
  - python -c "import iris"
  - bin/improver tests

Upgrade Travis to use Iris 2.
Upgrade Travis to use Iris 2.
