forked from conda/conda-build
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
73 lines (67 loc) · 2.28 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
language: python
matrix:
include:
- python: '2.7'
os: linux
- python: '3.4'
os: linux
- python: '3.5'
os: linux
# - python: '3.5'
# env: CANARY=true
# os: linux
- python: '3.5'
env: FLAKE8=true
os: linux
install:
- if [[ "$TRAVIS_PYTHON_VERSION" == "2.7" ]]; then
wget http://repo.continuum.io/miniconda/Miniconda2-latest-Linux-x86_64.sh -O miniconda.sh;
else
wget http://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
- conda update -q --all
- if [[ "$CANARY" == "true" ]]; then
conda install -y -q -c conda-canary conda;
conda config --set always_yes yes;
fi
- conda install -q --force --no-deps conda requests
- conda install -q anaconda-client requests filelock jinja2 patchelf python=$TRAVIS_PYTHON_VERSION pyflakes=1.1
- pip install pkginfo
- if [[ "$FLAKE8" == "true" ]]; then
conda install -q flake8;
else
conda install -q pytest pip pytest-cov numpy mock;
conda install -c conda-forge -q perl;
$HOME/miniconda/bin/pip install pytest-xdist pytest-capturelog;
pushd .. && git clone https://github.com/conda/conda_build_test_recipe && popd;
fi
- pip install --no-deps .
- conda info -a
script:
# flake8 and bdist_conda test together
- if [[ "$FLAKE8" == "true" ]]; then
flake8 .;
cp bdist_conda.py $HOME/miniconda/lib/python${TRAVIS_PYTHON_VERSION}/distutils/command;
pushd tests/bdist-recipe && python setup.py bdist_conda && popd;
conda build --help;
conda build conda.recipe --no-anaconda-upload -c conda-forge;
conda create -n _cbtest python=$TRAVIS_PYTHON_VERSION;
source activate _cbtest;
conda install $(conda render --output conda.recipe);
conda install filelock;
conda build conda.recipe --no-anaconda-upload -c conda-forge;
else
$HOME/miniconda/bin/py.test -v -n 2 --basetemp /tmp/cb --cov conda_build --cov-report xml tests;
fi
notifications:
flowdock: ef3821a08a791106512ccfc04c92eccb
git:
depth: 10000
sudo: false
after_success:
- pip install codecov
- codecov --env TRAVIS_PYTHON_VERSION