Fix for python 3

This commit is contained in:
sinhrks
2015-08-23 13:37:29 +09:00
parent 8e06726f6b
commit 00702dc39b
5 changed files with 33 additions and 11 deletions

View File

@@ -9,5 +9,11 @@ brew update
if [ ${TASK} == "python-package" ]; then
brew install python git graphviz
easy_install pip
pip install numpy scipy nose
pip install numpy scipy matplotlib nose
fi
if [ ${TASK} == "python-package3" ]; then
brew install python3 git graphviz
sudo pip3 install --upgrade setuptools
pip3 install numpy scipy matplotlib nose graphviz
fi

View File

@@ -35,11 +35,30 @@ fi
if [ ${TASK} == "python-package" ]; then
sudo apt-get install graphviz
sudo pip install matplotlib graphviz
sudo apt-get install python-numpy python-scipy python-matplotlib python-nose
sudo python -m pip install graphviz
make all CXX=${CXX} || exit -1
nosetests tests/python || exit -1
fi
if [ ${TASK} == "python-package3" ]; then
sudo apt-get install graphviz
# python3-matplotlib is unavailale on Ubuntu 12.04
sudo apt-get install python3-dev
sudo apt-get install python3-numpy python3-scipy python3-nose python3-setuptools
make all CXX=${CXX} || exit -1
if [ ${TRAVIS_OS_NAME} != "osx" ]; then
sudo easy_install3 pip
sudo easy_install3 -U distribute
sudo pip install graphviz matplotlib
nosetests3 tests/python || exit -1
else
nosetests tests/python || exit -1
fi
fi
# only test java under linux for now
if [ ${TASK} == "java-package" ]; then
if [ ${TRAVIS_OS_NAME} != "osx" ]; then