Skip to content

test(types): add public type checks#186

Merged
chenjiahan merged 1 commit intomainfrom
chenjiahan/test-exported-type-checks
Apr 2, 2026
Merged

test(types): add public type checks#186
chenjiahan merged 1 commit intomainfrom
chenjiahan/test-exported-type-checks

Conversation

@chenjiahan
Copy link
Copy Markdown
Member

Summary

  • add consumer-side type tests for @rspack/dev-server under both bundler and NodeNext resolution
  • disable skipLibCheck in those tests so exported declarations are validated as part of the test flow
  • wire the new type checks into test:type and test

Testing

  • pnpm run test:type

Related Links

  • None

@chenjiahan chenjiahan marked this pull request as ready for review April 2, 2026 08:48
Copilot AI review requested due to automatic review settings April 2, 2026 08:48
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds consumer-side TypeScript checks to validate @rspack/dev-server public declarations under both bundler and NodeNext module resolution modes, and wires these checks into the repo’s test workflow.

Changes:

  • Added two consumer-style type-test projects (resolution-bundler and resolution-nodenext) with skipLibCheck: false.
  • Added a tests workspace script to run tsc against both type-test projects.
  • Updated root test flow to run the new test:type step before rstest.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tests/type-tests/resolution-nodenext/tsconfig.json New NodeNext-resolution tsconfig with skipLibCheck: false for public type validation.
tests/type-tests/resolution-nodenext/index.ts Imports public entrypoints to force declaration/type resolution under NodeNext.
tests/type-tests/resolution-bundler/tsconfig.json New bundler-resolution tsconfig with skipLibCheck: false for public type validation.
tests/type-tests/resolution-bundler/index.ts Imports public entrypoints to force declaration/type resolution under bundler resolution.
tests/package.json Adds type-check script that runs tsc for both type-test projects.
package.json Adds test:type and wires it into test (runs build + tests workspace type-check).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@chenjiahan chenjiahan merged commit 18e1296 into main Apr 2, 2026
7 checks passed
@chenjiahan chenjiahan deleted the chenjiahan/test-exported-type-checks branch April 2, 2026 09:01
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.

2 participants