Title: test_doctest fails with non-ascii path
Type: behavior Stage: resolved
Components: Tests Versions: Python 2.7
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: flox Nosy List: flox, vstinner
Priority: normal Keywords: buildbot, patch

Created on 2010-01-10 18:11 by flox, last changed 2010-03-22 22:46 by flox. This issue is now closed.

File name Uploaded Description Edit
test_doctest.patch vstinner, 2010-01-21 03:34
Messages (4)
msg97533 - (view) Author: Florent Xicluna (flox) * (Python committer) Date: 2010-01-10 18:11
/tmp/py2u…→unicode $ ./python Lib/test/ test_doctest
File "/tmp/py2u…→unicode/Lib/test/", line 2052, in test.test_doctest.test_DocFileSuite
Failed example:
    <unittest.result.TestResult run=3 errors=0 failures=2>
    <unittest.result.TestResult run=3 errors=2 failures=0>
1 items had failures:
   1 of  40 in test.test_doctest.test_DocFileSuite
***Test Failed*** 1 failures.
test test_doctest failed -- 1 of 421 doctests failed

1 test failed:
msg98099 - (view) Author: STINNER Victor (vstinner) * (Python committer) Date: 2010-01-21 03:34
There are 2 different issues:
 * doctest.DocTestRunner.report_failure() raise an unicode error if the source line type is unicode: _failure_header() should convert the line to bytes using ASCII with backslashreplace error handler (as sys.stderr)
 * traceback.print_tb() raises an unicode error if the source line type is unicode: same solution (ASCII+bashslashreplace)

See also #Issue7708.
msg100183 - (view) Author: Florent Xicluna (flox) * (Python committer) Date: 2010-02-27 12:06
It should be fixed with patch attached to #1729305.
msg101545 - (view) Author: Florent Xicluna (flox) * (Python committer) Date: 2010-03-22 22:46
Really fixed with r79307.
Date User Action Args
2010-03-22 22:46:27floxsetresolution: accepted -> fixed
2010-03-22 22:46:17floxsetsuperseder: test_doctest fails when run in verbose mode ->
messages: + msg101545
2010-02-27 14:42:32floxsetstatus: open -> closed
resolution: accepted
stage: patch review -> resolved
2010-02-27 12:06:03floxsetsuperseder: test_doctest fails when run in verbose mode
messages: + msg100183
stage: test needed -> patch review
2010-02-26 15:32:25floxsetassignee: flox
type: behavior
2010-01-21 03:34:30vstinnersetfiles: + test_doctest.patch

nosy: + vstinner
messages: + msg98099

keywords: + patch
2010-01-15 16:31:07floxsetpriority: normal
keywords: + buildbot
stage: test needed
2010-01-10 18:11:52floxcreate