[Python-checkins] doc: fix a typo in unittest.mock.rst (GH-30227)
serhiy-storchaka
webhook-mailer at python.org
Sun Dec 26 06:09:24 EST 2021
https://github.com/python/cpython/commit/10bf0a9ac3c9bbde2fa8989d9435462f0e7da545
commit: 10bf0a9ac3c9bbde2fa8989d9435462f0e7da545
branch: main
author: Joe <nigelchiang at outlook.com>
committer: serhiy-storchaka <storchaka at gmail.com>
date: 2021-12-26T13:09:17+02:00
summary:
doc: fix a typo in unittest.mock.rst (GH-30227)
files:
M Doc/library/unittest.mock.rst
diff --git a/Doc/library/unittest.mock.rst b/Doc/library/unittest.mock.rst
index 0856c3fbded08..69f1035703ba5 100644
--- a/Doc/library/unittest.mock.rst
+++ b/Doc/library/unittest.mock.rst
@@ -1516,7 +1516,7 @@ attribute in a class) that does not exist will fail with :exc:`AttributeError`::
>>> test()
Traceback (most recent call last):
...
- AttributeError: <module 'sys' (built-in)> does not have the attribute 'non_existing'
+ AttributeError: <module 'sys' (built-in)> does not have the attribute 'non_existing_attribute'
but adding ``create=True`` in the call to :func:`patch` will make the previous example
work as expected::
More information about the Python-checkins
mailing list