gh-96624: Fix test_dotted_but_module_not_loaded in testpatch.py (GH-96691)

* Update test_dotted_but_module_not_loaded to reflect the move of unittest.test to test.test_unittest.
This commit is contained in:
Dennis Sweeney 2022-09-08 23:46:13 -04:00 committed by GitHub
parent df50938f58
commit 569ca27293
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 1 deletions

View File

@ -1923,7 +1923,7 @@ class PatchTest(unittest.TestCase):
del sys.modules['test.test_unittest.testmock.support']
del sys.modules['test.test_unittest.testmock']
del sys.modules['test.test_unittest']
del sys.modules['unittest']
del sys.modules['test']
# now make sure we can patch based on a dotted path:
@patch('test.test_unittest.testmock.support.X')

View File

@ -0,0 +1 @@
Fixed the failure of repeated runs of ``test.test_unittest`` caused by side effects in ``test_dotted_but_module_not_loaded``.