forked from SteveDoyle2/pyNastran
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
109 lines (92 loc) · 4.04 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
97
98
99
100
101
102
103
104
105
106
107
108
109
#os:
# - linux
# - osx
language: python
python:
- "2.7"
- "3.4"
- "3.5"
# - "3.6" # temporarily ignore
# - "3.5-dev" # 3.5 development branch
# - "nightly" # currently points to 3.6-dev
#-------------------------------------------------
# old-A
#before_install:
# - sudo apt-get update -qq
# - sudo apt-get install -qq python-dev python-setuptools python3-dev python3-setuptools libblas-dev liblapack-dev libatlas-base-dev gfortran
#
# command to install dependencies
#install: "pip install -r requirements.txt"
#
# command to run tests
#script: nosetests
#script: "python pyNastran/all_tests.py"
#-------------------------------------------------
#new-B
# per https://gist.github.com/dan-blanchard/7045057
#notifications:
# email: false
# Setup anaconda
before_install:
- sudo -H pip install auxlib
- sudo pip install conda
#install 2:
# - sudo conda init
# # Install packages
# - sudo conda update conda --yes
# - conda install --yes python=$TRAVIS_PYTHON_VERSION atlas numpy scipy vtk
# - export PATH=$HOME/py/bin:$PATH
# - python setup.py develop
# per http://conda.pydata.org/docs/travis.html
install:
- sudo apt-get update
- sudo apt-get install gfortran
# We do this conditionally because it saves us some downloading if the
# version is the same.
# v4.0 (latest) has a problem with auxlib, so switching to 3.19.0 (2016/3/23)
#wget https://repo.continuum.io/miniconda/Miniconda-latest-Linux-x86_64.sh -O miniconda.sh;
#wget https://repo.continuum.io/miniconda/Miniconda3-latest-Linux-x86_64.sh -O miniconda.sh;
- if [[ "$TRAVIS_PYTHON_VERSION" == "2.7" ]]; then
wget https://repo.continuum.io/miniconda/Miniconda2-4.1.11-Linux-x86_64.sh -O miniconda.sh;
else
wget https://repo.continuum.io/miniconda/Miniconda3-4.1.11-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 --set changeps1 no
- conda update -q conda
# Useful for debugging any issues with conda
- conda info -a
- conda install psutil pip
# - pip install coveralls
# install dependencies
# if line per https://docs.travis-ci.com/user/multi-os/
- echo "python version=$TRAVIS_PYTHON_VERSION"
- if [[ "$TRAVIS_PYTHON_VERSION" == "2.7" ]]; then conda create -q -n test-environment python=$TRAVIS_PYTHON_VERSION atlas numpy scipy matplotlib=1.5 pandas vtk pyqt; fi
- if [[ "$TRAVIS_PYTHON_VERSION" == "3.4" ]]; then conda create -q -n test-environment python=$TRAVIS_PYTHON_VERSION atlas numpy scipy matplotlib=1.5 pandas; fi
- if [[ "$TRAVIS_PYTHON_VERSION" == "3.5" ]]; then conda create -q -n test-environment python=$TRAVIS_PYTHON_VERSION atlas numpy scipy matplotlib=1.5 pandas; fi
- if [[ "$TRAVIS_PYTHON_VERSION" == "3.6" ]]; then conda create -q -n test-environment python=$TRAVIS_PYTHON_VERSION atlas numpy>=1.12 scipy matplotlib pandas; fi
- if [[ "$TRAVIS_PYTHON_VERSION" == "nightly" ]]; then conda create -q -n test-environment python=$TRAVIS_PYTHON_VERSION atlas numpy<1.13 scipy matplotlib=1.5 pandas; fi
- source activate test-environment
- conda list
- python setup.py develop
# Run test
script:
#- nosetests --with-cov --cov YOUR_PACKAGE_NAME_HERE --cov-config .coveragerc --logging-level=INFO
- if [[ "$TRAVIS_PYTHON_VERSION" == "2.7" ]]; then coverage run pyNastran/all_tests.py; fi
- if [[ "$TRAVIS_PYTHON_VERSION" == "3.4" ]]; then python pyNastran/all_tests_no_gui.py; fi
- if [[ "$TRAVIS_PYTHON_VERSION" == "3.5" ]]; then python pyNastran/all_tests_no_gui.py; fi
- if [[ "$TRAVIS_PYTHON_VERSION" == "3.6" ]]; then python pyNastran/all_tests_no_gui.py; fi
- if [[ "$TRAVIS_PYTHON_VERSION" == "nightly" ]]; then python pyNastran/all_tests_no_gui.py; fi
# good
#- "python pyNastran/all_tests.py"
#- "python -m coverage run pyNastran/all_tests_no_gui.py"
# good
#- "coverage run pyNastran/all_tests_no_gui.py"
# https://github.com/z4r/python-coveralls
# Calculate coverage
after_success:
- coveralls
#after_success:
# - coveralls --config_file .coveragerc