Repository navigation
fix #464 - bug: Test files are not covered by TypeScript typechecking - #468
Conversation
…ing and fix the TypeScript errors it exposes. Signed-off-by: Fabrizio Antonangeli <fabrizio.antonangeli@gmail.com>
Signed-off-by: Fabrizio Antonangeli <fabrizio.antonangeli@gmail.com>
🦋 Changeset detectedLatest commit: 24741f8 The changes in this PR will be included in the next version bump. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
✅ Deploy Preview for openworkflow-editor ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
There was a problem hiding this comment.
Copilot review overview
🟢 Approval recommended
Test configurations are consistently wired into workspace builds, and the exposed typing errors are addressed without changing production behavior.
Review effort: Balanced
Findings: None
What changed in this PR
Adds test-file type-checking across TypeScript workspaces and fixes errors exposed by stricter checks.
Changes:
- Adds test-specific TypeScript configurations and build scripts.
- Fixes test typings, Volar API usage, and Storybook helper inference.
- Adds release changeset entries for affected packages.
| File | Description |
|---|---|
.changeset/typecheck-test-files.md |
Records package patch changes. |
packages/text-editor/tsconfig.test.json |
Covers unit and E2E tests. |
packages/text-editor/package.json |
Runs test type-checking during builds. |
packages/text-editor/tests/text-editor/TextEditor.test.tsx |
Narrows mocked call access. |
packages/text-editor/stories/helpers.ts |
Improves story argument typing. |
packages/open-workflow-diagram-editor/tsconfig.test.json |
Covers unit and E2E tests. |
packages/open-workflow-diagram-editor/package.json |
Runs test type-checking during builds. |
packages/open-workflow-diagram-editor/tests/react-flow/diagram/diagramBuilder.test.ts |
Narrows task-reference typing. |
packages/open-workflow-diagram-editor/tests/react-flow/diagram/Diagram.test.tsx |
Narrows mocked call access. |
packages/open-workflow-diagram-editor/tests/react-flow/diagram/autoLayout.integration.test.ts |
Narrows indexed test results. |
packages/open-workflow-diagram-editor/tests/diagram-editor/DiagramEditor.test.tsx |
Uses the complete ref contract. |
packages/open-workflow-diagram-editor/tests/core/workflowSdk.integration.test.ts |
Narrows indexed errors. |
packages/open-workflow-diagram-editor/stories/helpers.ts |
Preserves precise story inference. |
packages/language-service/tsconfig.test.json |
Adds test type-checking configuration. |
packages/language-service/package.json |
Integrates type-checking into builds. |
packages/language-service/tests/volar/json/code-lenses.test.ts |
Updates tests for async Volar APIs. |
packages/language-service/tests/testUtils.ts |
Updates shared Volar test fixtures. |
packages/i18n/tsconfig.test.json |
Adds test type-checking configuration. |
packages/i18n/package.json |
Integrates type-checking into builds. |
examples/vanilla-web-component/tsconfig.test.json |
Covers example unit and E2E tests. |
examples/vanilla-web-component/package.json |
Integrates test type-checking into builds. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Closes #464
Describe the Bug
During the review of #463, we discovered typeScript errors in test files are not detected by our current package checks or CI.
Further investigation revealed that:
tsconfig.jsononly includessrc/**/*.tsconfig.test.jsonis not executed by any script inpackage.json.tsconfig.test.jsoninheritsrootDir: "./src", which causesTS6059errors when checking files undertests/.Using a temporary test-specific TypeScript configuration, I found 135 TypeScript errors in the Diagram Editor package.
How to test: