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:
Rishi Gupta 2016-10-06 22:07:02 -07:00 committed by Tim Abbott
parent 4b1a2adca5
commit ea050d5fd8
1 changed files with 1 additions and 1 deletions

View File

@ -107,7 +107,7 @@ def run_test(test):
print("Actual test to be run is %s, but import failed." % (actual_test_name,))
print("Importing test module directly to generate clearer traceback:")
try:
command = ["python", "-c", "import %s" % (actual_test_name,)]
command = ["python", "-c", "'import %s'" % (actual_test_name,)]
print("Import test command: `%s`" % (' '.join(command),))
subprocess.check_call(command)
except subprocess.CalledProcessError: