Skip to content

[codex] Fix main CI Effect test runtimes#3008

Merged
juliusmarminge merged 1 commit into
pingdotgg:mainfrom
juliusmarminge:codex/fix-main-ci
Jun 9, 2026
Merged

[codex] Fix main CI Effect test runtimes#3008
juliusmarminge merged 1 commit into
pingdotgg:mainfrom
juliusmarminge:codex/fix-main-ci

Conversation

@juliusmarminge

@juliusmarminge juliusmarminge commented Jun 9, 2026

Copy link
Copy Markdown
Member

Summary

  • migrate newly added Grok tests to @effect/vitest and test layers
  • run reactor dispatch assertions inside an Effect test
  • keep Grok adapter polling inside the Effect runtime

Root cause

The Grok provider merge introduced manual Effect.runPromise calls in backend tests. The repository lint rule t3code/no-manual-effect-runtime-in-tests rejects those calls, causing the Check job on main to fail.

Validation

  • vp check
  • vp run typecheck
  • vp test run apps/server/src/provider/acp/GrokAcpSupport.test.ts apps/server/src/provider/Layers/GrokProvider.test.ts apps/server/src/provider/Layers/GrokAdapter.test.ts apps/server/src/orchestration/Layers/ProviderCommandReactor.test.ts (50 tests)

Note

Fix CI test runtimes by migrating Effect tests to @effect/vitest

Replaces manual Effect.runPromise calls and custom runner helpers across four test files with @effect/vitest's it.effect and it.layer wrappers. Where needed, NodeServices.layer is now provided via it.layer(...) instead of a custom runNode helper. The waitForFileContent utility in GrokAdapter.test.ts is converted from async/Promise to an Effect-returning function that uses Effect.die on timeout instead of a rejected Promise.

Macroscope summarized 010c198.


Note

Low Risk
Test-only refactors with no production code changes; behavior assertions are preserved.

Overview
Fixes main CI Check failures from the t3code/no-manual-effect-runtime-in-tests lint rule by moving Grok-related and one reactor test off manual Effect.runPromise / custom runners.

Grok tests now use @effect/vitest (describe/it from that package, it.effect, and it.layer(NodeServices.layer) for status checks that need Node). The old runNode helper is removed in favor of layer-scoped tests.

GrokAdapter.test.ts: waitForFileContent is rewritten as an Effect that polls with Effect.sleep and fails via Effect.die on timeout; the stop-session test yields it directly instead of wrapping in Effect.promise.

ProviderCommandReactor.test.ts: The model-change rejection case is the only reactor test switched to effectIt.effect, with dispatches and assertions composed in Effect.gen (async harness setup still bridged with Effect.promise where needed).

Reviewed by Cursor Bugbot for commit 010c198. Bugbot is set up for automated code reviews on this repo. Configure here.

Co-authored-by: codex <codex@users.noreply.github.com>
@coderabbitai

coderabbitai Bot commented Jun 9, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 30d0bd6a-20b8-47de-a8ae-aceca6a8ff9b

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions github-actions Bot added the vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. label Jun 9, 2026
@juliusmarminge juliusmarminge marked this pull request as ready for review June 9, 2026 16:41
@github-actions github-actions Bot added the size:L 100-499 changed lines (additions + deletions). label Jun 9, 2026
@macroscopeapp

macroscopeapp Bot commented Jun 9, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Approved

Test-only changes that refactor test files to use @effect/vitest's it.effect() pattern instead of manual Effect.runPromise() calls. No production code is modified and the changes are mechanical in nature.

You can customize Macroscope's approvability policy. Learn more.

@juliusmarminge juliusmarminge merged commit 8e6f422 into pingdotgg:main Jun 9, 2026
20 of 21 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L 100-499 changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant