forked from CEA-COSMIC/pysap
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
88 lines (83 loc) · 3.14 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
sudo: required
dist: trusty
language: python
python:
- "2.7"
- "3.4"
- "3.5"
- "3.6"
before_install:
- sudo apt-get update
- sudo updatedb
- if [ $TRAVIS_PYTHON_VERSION == "2.7" ]; then
wget https://repo.continuum.io/miniconda/Miniconda2-latest-Linux-x86_64.sh -O miniconda.sh;
else
wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh;
fi
- if [ $TRAVIS_PYTHON_VERSION == "3.4" ]; then
export CPLUS_INCLUDE_PATH=/usr/include/python3.4m;
fi
- if [ $TRAVIS_PYTHON_VERSION == "3.5" ]; then
export CPLUS_INCLUDE_PATH=/opt/python/3.5.6/include/python3.5m;
fi
- if [ $TRAVIS_PYTHON_VERSION == "3.6" ]; then
export CPLUS_INCLUDE_PATH=/opt/python/3.6.3/include/python3.6m;
fi
- chmod +x miniconda.sh
- ./miniconda.sh -b -p $HOME/miniconda
- export PATH=$HOME/miniconda/bin:$PATH
- hash -r
- conda update --yes conda
- conda info -a
- sudo apt install -y libnfft3-dev
install:
- conda create -n testenv --yes pip python=$TRAVIS_PYTHON_VERSION
- source activate testenv
- if [ ${TRAVIS_PYTHON_VERSION:0:1} == "2" ]; then
pip install mock;
fi
- conda install --yes numpy scipy matplotlib
- if [ $TRAVIS_PYTHON_VERSION == "2.7" ]; then
pip install future;
fi
- locate pyconfig.h
- mkdir -p $HOME/.local/share/pysap
- git clone https://github.com/CEA-COSMIC/pysap-data.git $HOME/.local/share/pysap/pysap-data
- ln -s $HOME/.local/share/pysap/pysap-data/pysap-data/* $HOME/.local/share/pysap
- rm $HOME/.local/share/pysap/__init__.py
- ls -l $HOME/.local/share/pysap
- pip install cython
- pip install git+https://github.com/ghisvail/pyNFFT.git
- pip install nose
- pip install nose-exclude
- pip install coverage
- pip install coveralls
- pip install pycodestyle
- pip install sklearn
- pip install nibabel
- pip install progressbar2
- pip install astropy
- pip install PyWavelets
- pip install git+https://github.com/CEA-COSMIC/ModOpt@master
- pip install -b $TRAVIS_BUILD_DIR/build -t $TRAVIS_BUILD_DIR/install --no-clean .
- ls $TRAVIS_BUILD_DIR/install
- ldd $TRAVIS_BUILD_DIR/install/pysparse.so
- export PYTHONPATH=$TRAVIS_BUILD_DIR/install:$PYTHONPATH
- if [ $TRAVIS_PYTHON_VERSION == "2.7" ]; then
export PATH=$PATH:$TRAVIS_BUILD_DIR/build/temp.linux-x86_64-2.7/extern/bin;
fi
- if [ $TRAVIS_PYTHON_VERSION == "3.4" ]; then
export PATH=$PATH:$TRAVIS_BUILD_DIR/build/temp.linux-x86_64-3.4/extern/bin;
fi
- if [ $TRAVIS_PYTHON_VERSION == "3.5" ]; then
export PATH=$PATH:$TRAVIS_BUILD_DIR/build/temp.linux-x86_64-3.5/extern/bin;
fi
- if [ $TRAVIS_PYTHON_VERSION == "3.6" ]; then
export PATH=$PATH:$TRAVIS_BUILD_DIR/build/temp.linux-x86_64-3.6/extern/bin;
fi
script:
- python setup.py nosetests
- pycodestyle pysap --ignore="E121,E123,E126,E226,E24,E704,E402,E731,E722,E741,W503,W504,W605"
- pycodestyle examples --ignore="E121,E123,E126,E226,E24,E704,E402,E731,E741,W503,W504,W605"
after_success:
- coveralls