forked from qiskit-community/qiskit-ignis
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
115 lines (108 loc) · 2.55 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
110
111
112
113
114
115
cache:
pip: true
directories:
- .stestr
sudo: false
addons:
apt:
sources:
- ubuntu-toolchain-r-test
packages:
- gcc-4.8
- g++-4.8
- libblas-dev
- liblapack-dev
install_osx: &stage_osx
os: osx
osx_image: xcode9.2
language: generic
cache:
pip: true
directories:
- ~/python-interpreters/
- .stestr
before_install:
# Travis does not provide support for Python 3 under osx - it needs to be
# installed manually.
|
if [ ${TRAVIS_OS_NAME} = "osx" ]; then
if [[ ! -d ~/python-interpreters/$PYTHON_VERSION ]]; then
git clone git://github.com/pyenv/pyenv.git
cd pyenv/plugins/python-build
./install.sh
cd ../../..
python-build $PYTHON_VERSION ~/python-interpreters/$PYTHON_VERSION
fi
virtualenv --python ~/python-interpreters/$PYTHON_VERSION/bin/python venv
source venv/bin/activate
fi
before_script:
- |
if [ ! "$(ls -A .stestr)" ]; then
rm -r .stestr
fi
stages:
- lint_and_python
- all_python
matrix:
fast_finish: true
include:
- python: "3.5"
env: TOXENV=py35
name: "Python 3.5 Tests"
stage: lint_and_python
- python: "3.6"
env: TOXENV=py36
name: "Python 3.6 Tests"
stage: all_python
- os: linux
dist: xenial
python: "3.7"
env: TOXENV=py37
name: "Python 3.7 Tests"
stage: all_python
- python: "3.7"
dist: xenial
env: TOXENV=lint
name: "Linter Checks"
stage: lint_and_python
# OSX, Python 3.5.6 (via pyenv)
- stage: all_python
name: "Python 3.5 Tests on OSX"
<<: *stage_osx
env:
- MPLBACKEND=ps
- PYTHON_VERSION=3.5.6
- TOXENV=py35
# OSX, Python 3.6.5 (via pyenv)
- stage: all_python
name: "Python 3.6 Tests on OSX"
<<: *stage_osx
env:
- MPLBACKEND=ps
- PYTHON_VERSION=3.6.5
- TOXENV=py36
# OSX, Python 3.7.2 (via pyenv)
- stage: all_python
<<: *stage_osx
name: "Python 3.7 Tests on OSX"
env:
- MPLBACKEND=ps
- PYTHON_VERSION=3.7.2
- TOXENV=py37
- if: tag IS present
python: "3.6"
env:
- TWINE_USERNAME=qiskit
install: pip install -U twine
script:
- python3 setup.py sdist bdist_wheel
- twine upload dist/qiskit*
language: python
install: pip install -U tox pip virtualenv setuptools
script:
- tox --notest
- .tox/$TOXENV/bin/pip install --no-cache-dir --ignore-installed scs
- tox
notifications:
email: false