R. David Murray added the comment:
This doesn't have anything to do with NORMALIZE_WHITESPACE.
In python3, file.write returns the number of bytes written, instead of None.
If you add the 38 to the end of your test line, the test will pass.
This is not a bug in doctest, but a difference in
trambalda tramba...@gmail.com added the comment:
Same problem in 2.6.4 r264:75708 and 3.1 r31:73574
--
nosy: +trambalda
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7981
___
trambalda tramba...@gmail.com added the comment:
but with print() it works:
print(This text\n contains weird spacing.)
# doctest: +NORMALIZE_WHITESPACE
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7981