Skip to content

Conversation

@miss-islington
Copy link
Contributor

@miss-islington miss-islington commented Jun 18, 2024

Mocking only works if sys.modules['pydoc'] and pydoc are the same,
but some pydoc functions reload the module and change sys.modules.
Ensure that sys.modules['pydoc'] is always restored after the corresponding
tests.
(cherry picked from commit 2cf4738)

Co-authored-by: Serhiy Storchaka storchaka@gmail.com

…-120615)

Mocking only works if sys.modules['pydoc'] and pydoc are the same,
but some pydoc functions reload the module and change sys.modules.
Ensure that sys.modules['pydoc'] is always restored after the corresponding
tests.
(cherry picked from commit 2cf4738)

Co-authored-by: Serhiy Storchaka <storchaka@gmail.com>
@bedevere-app bedevere-app bot added the tests Tests in the Lib/test dir label Jun 18, 2024
@serhiy-storchaka serhiy-storchaka enabled auto-merge (squash) June 18, 2024 09:20
@serhiy-storchaka serhiy-storchaka merged commit 451cb71 into python:3.13 Jun 18, 2024
@miss-islington miss-islington deleted the backport-2cf4738-3.13 branch January 2, 2026 16:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip news tests Tests in the Lib/test dir

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants