From 87f61abda82e21fc77facd3931e0182dd564c3a0 Mon Sep 17 00:00:00 2001 From: cookedm Date: Wed, 26 Dec 2007 07:08:16 +0000 Subject: Replace numpy.distutils.exec_command.splitcmdline with shlex.split instead. It has the same problems as our old numpy.distutils.ccompiler.split_quoted. splitcmdline still exists, but uses shlex.split, and issues a DeprecationWarning This has the positive side effect of not having numpy.distutils pulled in when numpy is imported -- there was a use of splitcmdline in numpy.testing. --- numpy/testing/numpytest.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'numpy/testing/numpytest.py') diff --git a/numpy/testing/numpytest.py b/numpy/testing/numpytest.py index 9c9080fad..6a0e486aa 100644 --- a/numpy/testing/numpytest.py +++ b/numpy/testing/numpytest.py @@ -4,6 +4,7 @@ import sys import imp import glob import types +import shlex import unittest import traceback import warnings @@ -16,7 +17,6 @@ __all__ = ['set_package_path', 'set_local_path', 'restore_path', DEBUG=0 from numpy.testing.utils import jiffies -from numpy.distutils.exec_command import splitcmdline get_frame = sys._getframe class IgnoreException(Exception): @@ -649,7 +649,7 @@ class NumpyTest: type='string') (options, args) = parser.parse_args() return self.test(options.level,options.verbosity, - sys_argv=splitcmdline(options.sys_argv or ''), + sys_argv=shlex.split(options.sys_argv or ''), testcase_pattern=options.testcase_pattern) def warn(self, message): -- cgit v1.2.1