Skip to content

Fix TS5011 in e2e tsconfig by setting explicit rootDir#25

Merged
alchaplinsky merged 1 commit into
mainfrom
fix-e2e-tests
May 19, 2026
Merged

Fix TS5011 in e2e tsconfig by setting explicit rootDir#25
alchaplinsky merged 1 commit into
mainfrom
fix-e2e-tests

Conversation

@alchaplinsky

Copy link
Copy Markdown
Member

Summary

  • CI's bun run test:e2e failed because WDIO's config parser (ts-node) hit TS5011 when loading wdio.conf.ts under TypeScript 6 — the inferred common source dir became ./helpers from the helper import, which TS6 now requires to be explicit.
  • Setting "rootDir": "." in tests/e2e/tsconfig.json anchors compilation at the e2e root and unblocks the config load.

Test plan

  • Reproduce locally: bunx wdio run tests/e2e/wdio.conf.ts previously printed the TS5011 error twice and exited 1.
  • After the fix, the config loads cleanly and WDIO proceeds into onPrepare (mock server / Vite / app launch).
  • CI: confirm the GitHub Actions test:e2e job now passes the config-load step.

🤖 Generated with Claude Code

WDIO's config parser uses ts-node to compile wdio.conf.ts, and under
TypeScript 6 the inferred common source directory becomes './helpers'
(from the imported helper module), triggering TS5011. Setting rootDir
to "." anchors compilation at the e2e root and unblocks CI.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@greptile-apps

greptile-apps Bot commented May 19, 2026

Copy link
Copy Markdown

Greptile Summary

Adds a single "rootDir": "." compiler option to tests/e2e/tsconfig.json to fix the TS5011 error TypeScript 6 raises when the common source root cannot be inferred from include patterns alone.

  • The fix anchors ts-node compilation at tests/e2e/, which matches the existing "include": ["./**/*.ts"] scope — no files are affected beyond the config-load phase.
  • The root tsconfig.json already excludes tests/e2e/, so the change is fully self-contained within the e2e configuration.

Confidence Score: 5/5

Safe to merge — a one-line config addition that fixes a TypeScript 6 compilation error without touching any runtime code.

The change is confined to a single tsconfig field that aligns TypeScript's inferred root with the existing include glob. It has no effect on emitted output (since noEmit is inherited and ts-node uses transpileOnly), and the root tsconfig already isolates tests/e2e/ via exclude.

No files require special attention.

Reviews (1): Last reviewed commit: "Fix TS5011 in e2e tsconfig by setting ex..." | Re-trigger Greptile

@alchaplinsky
alchaplinsky merged commit b108577 into main May 19, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant