summaryrefslogtreecommitdiff
path: root/tools
diff options
context:
space:
mode:
authorJarrod Millman <jarrod.millman@gmail.com>2020-07-15 16:06:24 -0700
committerGitHub <noreply@github.com>2020-07-15 19:06:24 -0400
commit02097456ce2f8b164965e1ac3cb5ec14fcdf6d27 (patch)
tree63e7fc9a93b9eddaed9c266b70c8b2a703568eb2 /tools
parent3c2e2e895c75c185ccdc685446353f2be18f8f05 (diff)
downloadnetworkx-02097456ce2f8b164965e1ac3cb5ec14fcdf6d27.tar.gz
Use newer osx on travis (#4075)
Fixes #2614
Diffstat (limited to 'tools')
-rwxr-xr-xtools/travis/linux_install.sh4
-rwxr-xr-xtools/travis/osx_install.sh35
-rwxr-xr-xtools/travis/script.sh20
3 files changed, 13 insertions, 46 deletions
diff --git a/tools/travis/linux_install.sh b/tools/travis/linux_install.sh
index 821a1154..914e15e3 100755
--- a/tools/travis/linux_install.sh
+++ b/tools/travis/linux_install.sh
@@ -1,6 +1,8 @@
#!/usr/bin/env bash
set -ex
+section "Linux install section"
+
# create new empty venv
virtualenv -p python ~/venv
source ~/venv/bin/activate
@@ -25,4 +27,6 @@ EOF
fi
+section_end "Linux install section"
+
set +ex
diff --git a/tools/travis/osx_install.sh b/tools/travis/osx_install.sh
index a8626dce..5b0f47b1 100755
--- a/tools/travis/osx_install.sh
+++ b/tools/travis/osx_install.sh
@@ -1,36 +1,19 @@
#!/usr/bin/env bash
set -ex
-# set up Miniconda on OSX
-if [[ "${OSX_PKG_ENV}" == miniconda ]]; then
- wget https://repo.continuum.io/miniconda/Miniconda3-4.3.21-MacOSX-x86_64.sh -O miniconda.sh
- 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
+section "OSX install section"
- conda create -q -n testenv python=$TRAVIS_PYTHON_VERSION decorator
- source activate testenv
-else
- # set up Python and virtualenv on OSX
- git clone https://github.com/matthew-brett/multibuild
- sed -i "" 's/MACPYTHON_DEFAULT_OSX="10.6"/MACPYTHON_DEFAULT_OSX="10.9"/' multibuild/osx_utils.sh
- source multibuild/osx_utils.sh
- get_macpython_environment $TRAVIS_PYTHON_VERSION venv
-fi
+# set up Python and virtualenv on OSX
+git clone https://github.com/matthew-brett/multibuild
+source multibuild/osx_utils.sh
+get_macpython_environment $TRAVIS_PYTHON_VERSION venv
if [[ "${OPTIONAL_DEPS}" == 1 ]]; then
- if [[ "${OSX_PKG_ENV}" == miniconda ]]; then
- conda install graphviz=2.38
- export PKG_CONFIG_PATH=/Users/travis/miniconda/envs/testenv/lib/pkgconfig
- else
- brew install graphviz
- fi
+ brew install graphviz
dot -V
- sed -i "" 's/^gdal.*/gdal==1.11.2/' requirements/extras.txt
+ sed -i "" 's/^gdal.*/gdal==3.1.2/' requirements/extras.txt
fi
+section_end "OSX install section"
+
set +ex
diff --git a/tools/travis/script.sh b/tools/travis/script.sh
index b1b2d343..a5494a9e 100755
--- a/tools/travis/script.sh
+++ b/tools/travis/script.sh
@@ -4,33 +4,13 @@ set -e
section "script section"
-export NX_SOURCE=$PWD
-export NX_INSTALL=$(pip show networkx | grep Location | awk '{print $2"/networkx"}')
-
-# nose 1.3.0 does not tell coverage to only cover the requested
-# package (except during the report). So to restrict coverage, we must
-# inform coverage through the .coveragerc file.
-cp .coveragerc $NX_INSTALL
-
-# Move to new directory so that networkx is not imported from repository.
-# Why? Because we want the tests to make sure that NetworkX was installed
-# correctly. Example: setup.py might not have included some submodules.
-# Testing from the git repository cannot catch a mistake like that.
-#
-# Export current directory for logs.
-cd $NX_INSTALL
-printenv PWD
-
# Run pytest.
if [[ "${REPORT_COVERAGE}" == 1 ]]; then
pytest --cov=networkx --runslow --doctest-modules --pyargs networkx
- cp -a .coverage $NX_SOURCE
else
pytest --doctest-modules --durations=10 --pyargs networkx
fi
-cd $NX_SOURCE
-
section_end "script section"
set +e