8000 Inline $MPLLOCALFREETYPE/$PYTEST_ADDOPTS/$NPROC in .travis.yml. · matplotlib/matplotlib@4462d14 · GitHub
[go: up one dir, main page]

Skip to content

Commit 4462d14

Browse files
committed
Inline $MPLLOCALFREETYPE/$PYTEST_ADDOPTS/$NPROC in .travis.yml.
They're each used in only a single place so inlining them makes their usage simpler to follow. Also various small cleanups to .travis.yml.
1 parent b079233 commit 4462d14

File tree

1 file changed

+15
-20
lines changed

1 file changed

+15
-20
lines changed

.travis.yml

Lines changed: 15 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -57,22 +57,15 @@ env:
5757
- secure: RgJI7BBL8aX5FTOQe7xiXqWHMxWokd6GNUWp1NUV2mRLXPb9dI0RXqZt3UJwKTAzf1z/OtlHDmEkBoTVK81E9iUxK5npwyyjhJ8yTJmwfQtQF2n51Q1Ww9p+XSLORrOzZc7kAo6Kw6FIXN1pfctgYq2bQkrwJPRx/oPR8f6hcbY=
5858
- secure: E7OCdqhZ+PlwJcn+Hd6ns9TDJgEUXiUNEI0wu7xjxB2vBRRIKtZMbuaZjd+iKDqCKuVOJKu0ClBUYxmgmpLicTwi34CfTUYt6D4uhrU+8hBBOn1iiK51cl/aBvlUUrqaRLVhukNEBGZcyqAjXSA/Qsnp2iELEmAfOUa92ZYo1sk=
5959
- secure: dfjNqGKzQG5bu3FnDNwLG8H/C4QoieFo4PfFmZPdM2RY7WIzukwKFNT6kiDfOrpwt+2bR7FhzjOGlDECGtlGOtYPN8XuXGjhcP4a4IfakdbDfF+D3NPIpf5VlE6776k0VpvcZBTMYJKNFIMc7QPkOwjvNJ2aXyfe3hBuGlKJzQU=
60-
# Variables controlling the build.
61-
- MPLLOCALFREETYPE=1
62-
# Variable for the location of an extra pip requirement file
60+
# Variable for the location of an extra pip requirements file.
6361
- EXTRAREQS=
64-
# Variable for the location of a pip version file
62+
# Variable for the location of a pip constraints file.
6563
- PINNEDVERS=
6664
# Variables controlling the test run.
6765
- DELETE_FONT_CACHE=
6866
- NO_AT_BRIDGE=1 # Necessary for GTK3 interactive test.
69-
# The number of processes is hardcoded, because using too many causes the
70-
# Travis VM to run out of memory (since so many copies of inkscape and
71-
# ghostscript are running at the same time).
72-
- NPROC=2
7367
- OPENBLAS_NUM_THREADS=1
7468
- PYTHONFAULTHANDLER=1
75-
- PYTEST_ADDOPTS="-raR --maxfail=50 --timeout=300 --durations=25 --cov-report= --cov=lib -n $NPROC --log-level=DEBUG"
7669
- RUN_PYTEST=1
7770
- RUN_FLAKE8=
7871

@@ -110,10 +103,11 @@ matrix:
110103
- python: "nightly"
111104

112105
before_install: |
113-
# test with non-ascii in path
114-
if [[ $TRAVIS_OS_NAME != 'osx' ]]; then
106+
case "$TRAVIS_OS_NAME" in
107+
linux)
115108
export PATH=/usr/lib/ccache:$PATH
116-
else
109+
;;
110+
osx)
117111
ci/silence brew update
118112
brew uninstall numpy gdal postgis
119113
brew upgrade python
@@ -125,7 +119,8 @@ before_install: |
125119
# but this makes the test time really long.
126120
# brew install ghostscript inkscape
127121
export PATH=/usr/local/opt/python/libexec/bin:/usr/local/opt/ccache/libexec:$PATH
128-
fi
122+
;;
123+
esac
129124
130125
install:
131126
- |
@@ -159,28 +154,28 @@ install:
159154
echo 'wxPython is not available'
160155
161156
- |
162-
# Install matplotlib
163-
python -mpip install -ve .
157+
MPLLOCALFREETYPE=1 python -mpip install -ve . # Install Matplotlib.
164158
165159
before_script: |
166160
if [[ $DELETE_FONT_CACHE == 1 ]]; then
167161
rm -rf ~/.cache/matplotlib
168162
fi
169163
170164
script:
171-
# each script we want to run need to go in it's own section and the program you want
172-
# to fail travis need to be the last thing called
165+
# Each script we want to run need to go in its own section and the program
166+
# you want to fail travis needs to be the last thing called.
173167
- |
174168
if [[ $RUN_PYTEST == 1 ]]; then
175-
echo "Calling pytest with the following arguments: $PYTEST_ADDOPTS"
176-
python -mpytest
169+
# The number of processes is hardcoded (-n2), because using too many
170+
# causes the Travis VM to run out of memory (since so many copies of
171+
# inkscape and ghostscript are running at the same time).
172+
python -mpytest -raR --maxfail=50 --timeout=300 --durations=25 --cov-report= --cov=lib -n2 --log-level=DEBUG
177173
fi
178174
- |
179175
if [[ $RUN_FLAKE8 == 1 ]]; then
180176
flake8 --statistics &am 57AF p;& echo "Flake8 passed without any issues!"
181177
fi
182178
183-
184179
before_cache: |
185180
rm -rf $HOME/.cache/matplotlib/tex.cache
186181
rm -rf $HOME/.cache/matplotlib/test_cache

0 commit comments

Comments
 (0)
0