https://github.com/python/cpython/commit/348622a96d9554f639c6d692933ae476b3361b0b
commit: 348622a96d9554f639c6d692933ae476b3361b0b
branch: 3.13
author: Miss Islington (bot) <[email protected]>
committer: StanFromIreland <[email protected]>
date: 2026-06-13T18:37:47Z
summary:

[3.13] gh-151443: Fix documented default of  `unittest.mock.mock_open`'s 
`read_data` parameter (GH-151444)

(cherry picked from commit 9ad6ba0324a71ae5b51ded6e59b1ea3b653814a5)

Co-authored-by: Shardul Deshpande <[email protected]>

files:
M Doc/library/unittest.mock.rst

diff --git a/Doc/library/unittest.mock.rst b/Doc/library/unittest.mock.rst
index 8875ccadf6ad11..faf3f6f615e709 100644
--- a/Doc/library/unittest.mock.rst
+++ b/Doc/library/unittest.mock.rst
@@ -2539,7 +2539,7 @@ Alternatively you can just use ``vars(my_mock)`` 
(instance members) and
 mock_open
 ~~~~~~~~~
 
-.. function:: mock_open(mock=None, read_data=None)
+.. function:: mock_open(mock=None, read_data='')
 
    A helper function to create a mock to replace the use of :func:`open`. It 
works
    for :func:`open` called directly or used as a context manager.

_______________________________________________
Python-checkins mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3//lists/python-checkins.python.org
Member address: [email protected]

Reply via email to