This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: unittest.TestCase.assertNotEqual has incorrect docstring.
Type: enhancement Stage: resolved
Components: Library (Lib) Versions: Python 3.2, Python 3.3, Python 3.4, Python 2.7
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: ezio.melotti Nosy List: asvetlov, ezio.melotti, mark.dickinson, python-dev
Priority: normal Keywords:

Created on 2012-11-08 09:05 by mark.dickinson, last changed 2022-04-11 14:57 by admin. This issue is now closed.

Messages (7)
msg175142 - (view) Author: Mark Dickinson (mark.dickinson) * (Python committer) Date: 2012-11-08 09:05
The TestCase.assertNotEqual docstring currently says:

  Fail if the two objects are equal as determined by the '==' operator.

This doesn't match the implementation, which checks that '!=' gives True (rather than checking that '==' gives False).  The online docs look fine.
msg175145 - (view) Author: Roundup Robot (python-dev) (Python triager) Date: 2012-11-08 09:09
New changeset d32d04edd371 by Ezio Melotti in branch '2.7':
#16433: fix docstring of assertNotEqual.
http://hg.python.org/cpython/rev/d32d04edd371

New changeset 9d5cc978cfe5 by Ezio Melotti in branch '3.2':
#16433: fix docstring of assertNotEqual.
http://hg.python.org/cpython/rev/9d5cc978cfe5

New changeset e0fe5eead38a by Ezio Melotti in branch '3.3':
#16433: merge with 3.2.
http://hg.python.org/cpython/rev/e0fe5eead38a

New changeset 6eba4df6bb21 by Ezio Melotti in branch 'default':
#16433: merge with 3.3.
http://hg.python.org/cpython/rev/6eba4df6bb21
msg175146 - (view) Author: Ezio Melotti (ezio.melotti) * (Python committer) Date: 2012-11-08 09:10
Fixed, thanks for the report!
msg175147 - (view) Author: Mark Dickinson (mark.dickinson) * (Python committer) Date: 2012-11-08 09:10
Thanks, Ezio!
msg175150 - (view) Author: Andrew Svetlov (asvetlov) * (Python committer) Date: 2012-11-08 11:43
Maybe better to use: 
Fail if the two objects are *not* equal as determined by the '!=' operator.
???
msg175151 - (view) Author: Mark Dickinson (mark.dickinson) * (Python committer) Date: 2012-11-08 12:24
Andrew: if the objects are not equal, the test should pass, not fail.
msg175162 - (view) Author: Andrew Svetlov (asvetlov) * (Python committer) Date: 2012-11-08 14:16
Oops. Sorry, my fault.
History
Date User Action Args
2022-04-11 14:57:38adminsetgithub: 60637
2012-11-08 14:16:18asvetlovsetmessages: + msg175162
2012-11-08 12:24:32mark.dickinsonsetmessages: + msg175151
2012-11-08 11:43:07asvetlovsetnosy: + asvetlov
messages: + msg175150
2012-11-08 09:10:49mark.dickinsonsetmessages: + msg175147
2012-11-08 09:10:29ezio.melottisetstatus: open -> closed

type: enhancement
assignee: ezio.melotti

nosy: + ezio.melotti
messages: + msg175146
resolution: fixed
stage: resolved
2012-11-08 09:09:41python-devsetnosy: + python-dev
messages: + msg175145
2012-11-08 09:05:13mark.dickinsoncreate