Skip to content
This repository was archived by the owner on Feb 15, 2023. It is now read-only.

Commit 8fc5305

Browse files
committed
Adapt to pytest
1 parent 6ffe455 commit 8fc5305

File tree

2 files changed

+14
-3
lines changed

2 files changed

+14
-3
lines changed

config.sh

+1-3
Original file line numberDiff line numberDiff line change
@@ -60,9 +60,7 @@ function run_tests {
6060
if [ -z "$IS_OSX" ]; then
6161
extra="'full', $extra"
6262
fi
63-
local test_cmd="import sys; import scipy; \
64-
sys.exit(not scipy.test($extra).wasSuccessful())"
65-
python -c "$test_cmd"
63+
python ../run_scipy_tests.py $extra
6664
# Show BLAS / LAPACK used
6765
python -c 'import scipy; scipy.show_config()'
6866
}

run_scipy_tests.py

+13
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
""" Run scipy tests allowing for pytest and nosetests
2+
"""
3+
4+
import sys
5+
6+
import scipy
7+
8+
ret = scipy.test(*sys.argv[1:], verbose=3)
9+
if hasattr(ret, 'wasSuccessful'):
10+
# Nosetests version
11+
ret = ret.wasSuccessful()
12+
13+
sys.exit(not ret)

0 commit comments

Comments
 (0)