Kaydet (Commit) 0386b977 authored tarafından Tim Graham's avatar Tim Graham

Fixed test_runner test failure on Python 3.5; refs #23763.

Python change is http://bugs.python.org/issue22032
üst 1e219ac6
import sys
import unittest
from django.db import connection
......@@ -82,9 +83,12 @@ class TestDebugSQL(unittest.TestCase):
]
verbose_expected_outputs = [
'runTest (test_runner.test_debug_sql.FailingTest) ... FAIL',
'runTest (test_runner.test_debug_sql.ErrorTest) ... ERROR',
'runTest (test_runner.test_debug_sql.PassingTest) ... ok',
# Output format changed in Python 3.5+
x.format('' if sys.version_info < (3, 5) else 'TestDebugSQL.') for x in [
'runTest (test_runner.test_debug_sql.{}FailingTest) ... FAIL',
'runTest (test_runner.test_debug_sql.{}ErrorTest) ... ERROR',
'runTest (test_runner.test_debug_sql.{}PassingTest) ... ok',
]
]
if six.PY3:
verbose_expected_outputs += [
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment