https://github.com/python/cpython/commit/f8e9c57067e32baab4ed2fd824b892c52ecb7225
commit: f8e9c57067e32baab4ed2fd824b892c52ecb7225
branch: main
author: Nikita Sobolev <[email protected]>
committer: sobolevn <[email protected]>
date: 2024-02-11T11:51:25+03:00
summary:
gh-115274: Fix direct invocation of `testmock/testpatch.py` (#115275)
files:
M Lib/test/test_unittest/testmock/testpatch.py
diff --git a/Lib/test/test_unittest/testmock/testpatch.py
b/Lib/test/test_unittest/testmock/testpatch.py
index 833d7da1f31a20..d0046d702a53f4 100644
--- a/Lib/test/test_unittest/testmock/testpatch.py
+++ b/Lib/test/test_unittest/testmock/testpatch.py
@@ -1912,7 +1912,7 @@ def foo(x=0):
with patch.object(foo, '__module__', "testpatch2"):
self.assertEqual(foo.__module__, "testpatch2")
- self.assertEqual(foo.__module__,
'test.test_unittest.testmock.testpatch')
+ self.assertEqual(foo.__module__, __name__)
with patch.object(foo, '__annotations__', dict([('s', 1, )])):
self.assertEqual(foo.__annotations__, dict([('s', 1, )]))
_______________________________________________
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]