Message376457
When verbosity level is more than 1 the test tries to print the script_exec_args passed to script. It fails when the tuple has more than 1 elements and is used in formatting with %r. The two tests fail as below :
./python -m test test_cmd_line_script -vv
======================================================================
ERROR: test_package_error (test.test_cmd_line_script.CmdLineTest)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/root/cpython/Lib/test/test_cmd_line_script.py", line 368, in test_package_error
self._check_import_error(["-m", "test_pkg"], msg, cwd=script_dir)
File "/root/cpython/Lib/test/test_cmd_line_script.py", line 148, in _check_import_error
print('Output from test script %r:' % script_exec_args)
TypeError: not all arguments converted during string formatting
======================================================================
ERROR: test_package_recursion (test.test_cmd_line_script.CmdLineTest)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/root/cpython/Lib/test/test_cmd_line_script.py", line 379, in test_package_recursion
self._check_import_error(["-m", "test_pkg"], msg, cwd=script_dir)
File "/root/cpython/Lib/test/test_cmd_line_script.py", line 148, in _check_import_error
print('Output from test script %r:' % script_exec_args)
TypeError: not all arguments converted during string formatting
----------------------------------------------------------------------
Ran 44 tests in 4.936s
FAILED (errors=2)
test test_cmd_line_script failed
test_cmd_line_script failed
== Tests result: FAILURE ==
1 test failed:
test_cmd_line_script
Total duration: 5.0 sec
Tests result: FAILURE |
|
Date |
User |
Action |
Args |
2020-09-06 04:57:49 | xtreak | set | recipients:
+ xtreak |
2020-09-06 04:57:49 | xtreak | set | messageid: <1599368269.38.0.401478917428.issue41731@roundup.psfhosted.org> |
2020-09-06 04:57:49 | xtreak | link | issue41731 messages |
2020-09-06 04:57:49 | xtreak | create | |
|