Issue #20487: Clarify meaning of "side effect" in the magic mock documentation.

Patch by A.M. Kuchling.
This commit is contained in:
Berker Peksag 2015-01-07 21:15:02 +02:00
parent b9fdb7a452
commit 283f1aa881
1 changed files with 4 additions and 3 deletions

View File

@ -1678,9 +1678,10 @@ For example:
>>> object() in mock
False
The two equality method, :meth:`__eq__` and :meth:`__ne__`, are special.
They do the default equality comparison on identity, using a side
effect, unless you change their return value to return something else:
The two equality methods, :meth:`__eq__` and :meth:`__ne__`, are special.
They do the default equality comparison on identity, using the
:attr:`~Mock.side_effect` attribute, unless you change their return value to
return something else::
>>> MagicMock() == 3
False