forked from daltonkell/compliance-checker
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
96 lines (85 loc) · 2.95 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
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
language: python
sudo: false
matrix:
fast_finish: true
include:
- python: 2.7
env: TEST_TARGET=default
- python: 2.7
env: TEST_TARGET=integration
- python: 3.5
env: TEST_TARGET=default
- python: 3.6
env: TEST_TARGET=default
- python: 3.6
env: TEST_TARGET=coding_standards
- python: 3.6
env: TEST_TARGET=integration
- python: 3.6
env: TEST_TARGET=cc-plugin-glider
- python: 3.6
env: TEST_TARGET=cc-plugin-ncei
- python: 3.6
env: TEST_TARGET=cc-plugin-sgrid
- python: 3.6
env: TEST_TARGET=cc-checker-ugrid
allow_failures:
- python: 3.6
env: TEST_TARGET=coding_standards
- python: 2.7
env: TEST_TARGET=integration
- python: 3.6
env: TEST_TARGET=integration
- python: 3.6
env: TEST_TARGET=cc-plugin-glider
- python: 3.6
env: TEST_TARGET=cc-plugin-ncei
- python: 3.6
env: TEST_TARGET=cc-plugin-sgrid
- python: 3.6
env: TEST_TARGET=cc-checker-ugrid
before_install:
- wget http://bit.ly/miniconda -O miniconda.sh
- bash miniconda.sh -b -p $HOME/miniconda
- export PATH="$HOME/miniconda/bin:$PATH"
- conda config --set always_yes yes --set changeps1 no --set show_channel_urls true
- conda update conda
- conda config --add channels conda-forge --force
- conda create --name TEST python=$TRAVIS_PYTHON_VERSION --file requirements.txt --file test_requirements.txt
- source activate TEST
- if [[ "$TRAVIS_PYTHON_VERSION" == "2.7" ]]; then
conda install --yes httpretty ;
fi
# Test source distribution.
install:
- python setup.py sdist && version=$(python setup.py --version) && pushd dist && pip install compliance-checker-${version}.tar.gz && popd
script:
- if [[ $TEST_TARGET == "default" ]]; then
py.test -k "not integration" -s -rxs -v ;
fi
- if [[ $TEST_TARGET == "coding_standards" ]]; then
flake8 --ignore=E501,E251,E221,E201,E202,E203 -qq --statistics . ;
fi
- if [[ $TEST_TARGET == "integration" ]]; then
py.test -m "integration" -s -rxs -v ;
fi
- if [[ $TEST_TARGET == 'cc-plugin-glider' ]]; then
git clone https://github.com/ioos/cc-plugin-glider.git && cd cc-plugin-glider ;
conda install --file requirements.txt --file requirements-dev.txt ;
py.test -s -rxs -v ;
fi
- if [[ $TEST_TARGET == 'cc-plugin-ncei' ]]; then
git clone https://github.com/ioos/cc-plugin-ncei.git && cd cc-plugin-ncei ;
conda install --file requirements.txt --file requirements-dev.txt ;
py.test -s -rxs -v ;
fi
- if [[ $TEST_TARGET == 'cc-plugin-sgrid' ]]; then
git clone https://github.com/ioos/cc-plugin-sgrid.git && cd cc-plugin-sgrid ;
conda install --file requirements.txt --file requirements-dev.txt ;
py.test -s -rxs -v ;
fi
- if [[ $TEST_TARGET == 'cc-checker-ugrid' ]]; then
git clone https://github.com/ioos/cc-checker-ugrid.git && cd cc-checker-ugrid ;
conda install --file requirements.txt --file requirements-dev.txt ;
py.test -s -rxs -v ;
fi