mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
gh-95212: make multiprocessing test case parallel-safe (GH-95213)
This commit is contained in:
parent
3e718cf880
commit
5956de16cd
2 changed files with 3 additions and 1 deletions
|
@ -3973,7 +3973,7 @@ class _TestSharedMemory(BaseTestCase):
|
|||
'multiprocessing.shared_memory._make_filename') as mock_make_filename:
|
||||
|
||||
NAME_PREFIX = shared_memory._SHM_NAME_PREFIX
|
||||
names = ['test01_fn', 'test02_fn']
|
||||
names = [self._new_shm_name('test03_fn'), self._new_shm_name('test04_fn')]
|
||||
# Prepend NAME_PREFIX which can be '/psm_' or 'wnsm_', necessary
|
||||
# because some POSIX compliant systems require name to start with /
|
||||
names = [NAME_PREFIX + name for name in names]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue