mirror of https://github.com/zulip/zulip.git
test_runner: Fix error message for failed import.
Previously, we suggested running `python -c import zerver.tests.test_mytest` when importing test_mytest failed, which doesn't work. This commit adds the missing quotes, making it `python -c 'import zerver.tests.test_mytest'`
This commit is contained in:
parent
4b1a2adca5
commit
ea050d5fd8
|
@ -107,7 +107,7 @@ def run_test(test):
|
||||||
print("Actual test to be run is %s, but import failed." % (actual_test_name,))
|
print("Actual test to be run is %s, but import failed." % (actual_test_name,))
|
||||||
print("Importing test module directly to generate clearer traceback:")
|
print("Importing test module directly to generate clearer traceback:")
|
||||||
try:
|
try:
|
||||||
command = ["python", "-c", "import %s" % (actual_test_name,)]
|
command = ["python", "-c", "'import %s'" % (actual_test_name,)]
|
||||||
print("Import test command: `%s`" % (' '.join(command),))
|
print("Import test command: `%s`" % (' '.join(command),))
|
||||||
subprocess.check_call(command)
|
subprocess.check_call(command)
|
||||||
except subprocess.CalledProcessError:
|
except subprocess.CalledProcessError:
|
||||||
|
|
Loading…
Reference in New Issue