test(events): cover parallel project command execution#6469
Open
krewenki wants to merge 2 commits into
Open
Conversation
Add a deterministic channel-barrier regression test for the shared parallel plan and apply executor path. The test proves both projects enter execution before either can complete. Signed-off-by: Warren Krewenki <19960+krewenki@users.noreply.github.com> Co-authored-by: Codex <noreply@openai.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Adds a deterministic regression test that verifies the shared project command pool executor actually runs multiple projects concurrently (not just “eventually succeeds”) for both plan and apply.
Changes:
- Adds
TestRunProjectCmdsWithCancellationTracker_ParallelPlanAndApplyRunConcurrentlycovering bothcommand.Planandcommand.Apply. - Uses a blocking runner plus
entered/completedchannels to prove two projects enter execution before either is allowed to complete.
nitrocode
approved these changes
May 15, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Adds a deterministic regression test for the shared project command pool executor used by parallel plan and parallel apply.
The new test covers both
command.Planandcommand.Apply, starts two projects in the same execution-order group with a pool size of two, and uses channels to prove both projects enter execution before either one is allowed to complete.Why
The existing executor tests showed that commands completed, but they did not prove that more than one project was actually in flight before completion. This catches regressions where the parallel executor path accidentally becomes serialized while still returning successful results.
Validation
gofmt -w server/events/project_command_pool_executor_test.goGOCACHE=/private/tmp/codex-go-build go test ./server/events -run 'TestRunProjectCmdsWithCancellationTracker_ParallelPlanAndApplyRunConcurrently|TestRunProjectCmdsParallel|TestRunProjectCmdsWithCancellationTracker'goimports -l server/events/project_command_pool_executor_test.gogit diff --check