Skip to content

Commit 864e78c

Browse files
committed
modify tests for python3
1 parent c1fb5e6 commit 864e78c

File tree

1 file changed

+19
-14
lines changed

1 file changed

+19
-14
lines changed

.travis.yml

Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3,19 +3,24 @@
33
#
44

55
language: erlang
6-
python:
7-
- "2.7"
8-
# command to install dependencies
6+
env:
7+
- PYTHON=python PYSUF='' PYVER=2.7
8+
- PYTHON=python3 PYSUF='3' PYVER=3.2
99
install:
10-
- sudo apt-get update -qq # needed for python3-numpy
11-
- sudo apt-get install -qq python-dev
12-
- sudo apt-get install -qq python-numpy
13-
- sudo apt-get install -qq python-scipy
14-
- sudo apt-get install -qq python-setuptools
15-
- sudo apt-get install -qq python-matplotlib
16-
- sudo apt-get install -qq python-nose
17-
18-
# command to run tests
10+
- sudo apt-get update # needed for python3-numpy
11+
- sudo apt-get install $PYTHON-dev
12+
- sudo apt-get install $PYTHON-numpy
13+
- sudo apt-get install $PYTHON-scipy
14+
- sudo apt-get install $PYTHON-setuptools
15+
- sudo apt-get install $PYTHON-nose
16+
- sudo easy_install$PYSUF pip
17+
- if [[ $PYVER == '2.7' ]]; then sudo apt-get install $PYTHON-matplotlib; fi
18+
- if [[ $PYVER == '3.2' ]]; then sudo pip-$PYVER install git+git://github.com/matplotlib/[email protected]; fi
19+
- $PYTHON setup.py build
20+
- sudo $PYTHON setup.py install
1921
script:
20-
- sudo python setup.py build install
21-
- nosetests
22+
# Change into an innocuous directory and find tests from installation
23+
- mkdir $HOME/.matplotlib
24+
- "echo 'backend : Agg' > $HOME/.matplotlib/matplotlibrc"
25+
- "echo 'backend.qt4 : PyQt4' >> $HOME/.matplotlib/matplotlibrc"
26+
- nosetests-$PYVER

0 commit comments

Comments
 (0)