summaryrefslogtreecommitdiff
path: root/numpy/tests/test_scripts.py
diff options
context:
space:
mode:
authorCharles Harris <charlesr.harris@gmail.com>2017-07-04 13:47:45 -0600
committerCharles Harris <charlesr.harris@gmail.com>2017-07-04 19:51:58 -0600
commitae84af3b6e6d96e4be408e8a56408290ee1879db (patch)
tree0eff73d96f270e8d3aed3fc660e9926f023fde0d /numpy/tests/test_scripts.py
parent0e4253526c727f50696f6233fee3d50a419ba9fe (diff)
downloadnumpy-ae84af3b6e6d96e4be408e8a56408290ee1879db.tar.gz
MAINT: Rearrange files in numpy/testing module.
The aim here is to separate out the nose dependent files prior to adding pytest support. This could be done by adding new files to the general numpy/testing directory, but I felt that it was to have the relevant files separated out as it makes it easier to completely remove nose dependencies when needed. Many places were accessing submodules in numpy/testing directly, and in some cases incorrectly. That presented a backwards compatibility problem. The solution adapted here is to have "dummy" files whose contents will depend on whether of not pytest is active. That way the module looks the same as before from the outside. In the case of numpy itself, direct accesses have been fixed. Having proper `__all__` lists in the submodules helped in that.
Diffstat (limited to 'numpy/tests/test_scripts.py')
-rw-r--r--numpy/tests/test_scripts.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/numpy/tests/test_scripts.py b/numpy/tests/test_scripts.py
index 431e08d1b..675fe6575 100644
--- a/numpy/tests/test_scripts.py
+++ b/numpy/tests/test_scripts.py
@@ -11,8 +11,7 @@ from subprocess import Popen, PIPE
import numpy as np
from numpy.compat.py3k import basestring
from nose.tools import assert_equal
-from numpy.testing.decorators import skipif
-from numpy.testing import assert_
+from numpy.testing import assert_, dec
is_inplace = isfile(pathjoin(dirname(np.__file__), '..', 'setup.py'))
@@ -59,7 +58,7 @@ def run_command(cmd, check_code=True):
return proc.returncode, stdout, stderr
-@skipif(is_inplace)
+@dec.skipif(is_inplace)
def test_f2py():
# test that we can run f2py script
if sys.platform == 'win32':