Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(10)

Unified Diff: Doc/library/unittest.mock.rst

Issue 18758: Fix internal references in the documentation
Patch Set: Created 6 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Doc/library/time.rst ('k') | Doc/library/warnings.rst » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
--- a/Doc/library/unittest.mock.rst Wed Oct 09 14:20:37 2013 +0300
+++ b/Doc/library/unittest.mock.rst Wed Oct 09 16:49:06 2013 +0300
@@ -210,7 +210,7 @@
Accessing any attribute not in this list will raise an `AttributeError`.
If `spec` is an object (rather than a list of strings) then
- :attr:`__class__` returns the class of the spec object. This allows mocks
+ :attr:`~instance.__class__` returns the class of the spec object. This allows mocks
to pass `isinstance` tests.
* `spec_set`: A stricter variant of `spec`. If used, attempting to *set*
@@ -1989,7 +1989,8 @@
default) then a `MagicMock` will be created for you, with the API limited
to methods or attributes available on standard file handles.
- `read_data` is a string for the `read`, `readline`, and `readlines` methods
+ `read_data` is a string for the :meth:`~io.IOBase.read`,
+ :meth:`~io.IOBase.readline`, and :meth:`~io.IOBase.readlines` methods
of the file handle to return. Calls to those methods will take data from
`read_data` until it is depleted. The mock of these methods is pretty
simplistic. If you need more control over the data that you are feeding to
« no previous file with comments | « Doc/library/time.rst ('k') | Doc/library/warnings.rst » ('j') | no next file with comments »

RSS Feeds Recent Issues | This issue
This is Rietveld 894c83f36cb7+