This repository has been archived by the owner on Feb 25, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix some races in the platform isolate tests (#51358)
* Do not check IsolateIsShutdown after CreateAndRegisterIsolate in the MultithreadedCreation test. The test's main thread could run ShutdownPlatformIsolates between a worker thread's calls to CreateAndRegisterIsolate and IsolateIsShutdown. If that happens, IsolateIsShutdown will return true even though CreateAndRegisterIsolate succeeded. * Change the is_registered flag to was_registered and do not clear it during isolate shutdown Tests like MultithreadedCreation need to know whether RegisterPlatformIsolate succeeded so they can determine if the isolate will be shut down by ShutdownPlatformIsolates or if it needs to be shut down explicitly. If the flag is cleared during shutdown, then the test may see an isolate that was successfully registered and shut down and think that it was never registered.
- Loading branch information
1 parent
e3f3c02
commit ea848c3
Showing
1 changed file
with
12 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters