perf(v4): skip the eager stack capture when building a ZodError #5602
Workflow file for this run
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
| name: test | |
| on: | |
| push: | |
| branches: | |
| - "main" | |
| pull_request: | |
| branches: | |
| - main | |
| - v4 | |
| permissions: | |
| contents: read | |
| jobs: | |
| test-node: | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| os: [ubuntu-latest] | |
| node: ["lts/*"] | |
| typescript: ["5.5", "6", "latest"] | |
| name: Test with TypeScript ${{ matrix.typescript }} on Node ${{ matrix.node }} (${{ matrix.os }}) | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - uses: actions/setup-node@v7 | |
| with: | |
| node-version: ${{ matrix.node }} | |
| - uses: pnpm/action-setup@v6 | |
| - run: pnpm install | |
| # Build with the repo-pinned TypeScript: zshy uses the classic compiler API, | |
| # which TypeScript 7 no longer ships. The matrix version applies to the tests. | |
| - run: pnpm build | |
| - run: pnpm add typescript@${{ matrix.typescript }} -w | |
| - run: pnpm test | |
| # test-resolution.ts shells out to zshy, so it can't run under TypeScript 7. | |
| - run: pnpm run --filter @zod/resolution test:all | |
| if: matrix.typescript != 'latest' | |
| - run: pnpm run --filter @zod/integration test:all | |
| lint: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| node: ["latest"] | |
| name: Lint on Node ${{ matrix.node }} | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - uses: actions/setup-node@v7 | |
| with: | |
| node-version: ${{ matrix.node }} | |
| - uses: pnpm/action-setup@v6 | |
| - run: pnpm install | |
| - run: pnpm format:check | |
| - run: pnpm lint:check | |
| - run: pnpm check:comments | |
| check-circular: | |
| runs-on: ubuntu-latest | |
| name: Check for circular dependencies | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - uses: actions/setup-node@v7 | |
| with: | |
| node-version: "latest" | |
| - uses: pnpm/action-setup@v6 | |
| - run: pnpm install | |
| - run: pnpm check:circular |