[issue30304] TestCase.assertMultiLineEqual only registered for Unicode strings in 2.7
New submission from Martin Panter: In Mercurial revision 6e5b5d1b6714, the documentation for “assertMultiLineEqual” was changed from This method is used by default when comparing Unicode strings with “assertEqual”. to This method is used by default when comparing strings with “assertEqual”. The new text is misleading because “str” objects are also strings, but the default does not apply to “str” objects. ---------- assignee: docs@python components: Documentation, Tests keywords: easy messages: 293229 nosy: docs@python, ezio.melotti, martin.panter priority: normal severity: normal stage: needs patch status: open title: TestCase.assertMultiLineEqual only registered for Unicode strings in 2.7 type: behavior versions: Python 2.7 _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Sourav Singh added the comment: @Martin I would like to take a stab at the issue. How do I start? ---------- nosy: +Sourav Singh _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Martin Panter added the comment: I think the simplest way forward would be to add the word “Unicode” back in. You could look at making a Git Hub pull request for this if you want. Hopefully somebody else can merge it though, because I probably won’t be in a position to do so for a while. ---------- _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Changes by Aditya Hase <aditya@adityahase.com>: ---------- pull_requests: +2891 _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Aditya Hase added the comment: Hi, I'm new to python development community. I've created a GitHub PR that fixes this issue. ---------- nosy: +adityahase _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Changes by Mariatta Wijaya <mariatta.wijaya@gmail.com>: ---------- stage: needs patch -> patch review versions: +Python 3.5, Python 3.6, Python 3.7 _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Serhiy Storchaka added the comment: This is related only to 2.7. All correct in 3.x. ---------- nosy: +serhiy.storchaka versions: -Python 3.5, Python 3.6, Python 3.7 _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Mariatta Wijaya added the comment: Thanks Serhiy. Aditya, your PR was made against the master branch. Can you make the change against the 2.7 branch? Thanks. ---------- nosy: +Mariatta _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Changes by Aditya Hase <aditya@adityahase.com>: ---------- pull_requests: +2893 _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Aditya Hase added the comment: I've fixed that. ---------- versions: +Python 3.5, Python 3.6, Python 3.7 _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Changes by Serhiy Storchaka <storchaka+cpython@gmail.com>: ---------- versions: -Python 3.5, Python 3.6, Python 3.7 _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Mariatta Wijaya added the comment: New changeset 0666d0e50432e3b0109db96b8e48fb6c496bd49c by Mariatta (Aditya Hase) in branch '2.7': bpo-30304: Improve TestCase.assertMultiLineEqual docs (GH-2847) https://github.com/python/cpython/commit/0666d0e50432e3b0109db96b8e48fb6c496... ---------- _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
Mariatta Wijaya added the comment: Thanks! ---------- resolution: -> fixed stage: patch review -> resolved status: open -> closed _______________________________________ Python tracker <report@bugs.python.org> <http://bugs.python.org/issue30304> _______________________________________
participants (5)
-
Aditya Hase -
Mariatta Wijaya -
Martin Panter -
Serhiy Storchaka -
Sourav Singh