test(e2e): reorganize manifest related cases #6889
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: | |
| pull_request: | |
| branches: [main] | |
| push: | |
| branches: [main] | |
| workflow_dispatch: | |
| permissions: | |
| contents: read | |
| env: | |
| # Configure Node.js memory limit to 6GB (default GitHub Actions limit is 7GB) | |
| NODE_OPTIONS: --max-old-space-size=6144 | |
| jobs: | |
| # ======== ut ======== | |
| ut: | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 15 | |
| strategy: | |
| matrix: | |
| # run ut on macOS, as SWC cases will fail on Ubuntu CI | |
| os: [macos-latest, windows-latest] | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0 | |
| with: | |
| fetch-depth: 1 | |
| - name: Install Pnpm | |
| run: | | |
| npm install -g corepack@latest --force | |
| corepack enable | |
| - uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2 | |
| id: changes | |
| with: | |
| predicate-quantifier: 'every' | |
| filters: | | |
| changed: | |
| - "!**/*.md" | |
| - "!**/*.mdx" | |
| - "!**/_meta.json" | |
| - "!**/dictionary.txt" | |
| - name: Setup Node.js | |
| if: steps.changes.outputs.changed == 'true' | |
| uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0 | |
| with: | |
| node-version: '22.20' | |
| package-manager-cache: false | |
| - name: Install Dependencies | |
| if: steps.changes.outputs.changed == 'true' | |
| run: pnpm install | |
| - name: Unit Test | |
| if: steps.changes.outputs.changed == 'true' | |
| run: pnpm test | |
| # ======== e2e ======== | |
| e2e: | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 15 | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, windows-latest] | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0 | |
| with: | |
| fetch-depth: 1 | |
| - name: Install Pnpm | |
| run: | | |
| npm install -g corepack@latest --force | |
| corepack enable | |
| - uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2 | |
| id: changes | |
| with: | |
| predicate-quantifier: 'every' | |
| filters: | | |
| changed: | |
| - "!**/*.md" | |
| - "!**/*.mdx" | |
| - "!**/_meta.json" | |
| - "!**/dictionary.txt" | |
| - name: Setup Node.js | |
| if: steps.changes.outputs.changed == 'true' | |
| uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0 | |
| with: | |
| node-version: '22.20' | |
| package-manager-cache: false | |
| - name: Install Dependencies | |
| if: steps.changes.outputs.changed == 'true' | |
| run: pnpm install && cd ./e2e && pnpm run setup | |
| - name: E2E Test - 1 | |
| if: steps.changes.outputs.changed == 'true' | |
| run: pnpm run e2e:rspack --shard=1/2 | |
| - name: E2E Test - 2 | |
| if: steps.changes.outputs.changed == 'true' | |
| run: pnpm run e2e:rspack --shard=2/2 | |
| # ======== e2e-webpack ======== | |
| e2e-webpack: | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 15 | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, windows-latest] | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@1af3b93b6815bc44a9784bd300feb67ff0d1eeb3 # v6.0.0 | |
| with: | |
| fetch-depth: 1 | |
| - name: Install Pnpm | |
| run: | | |
| npm install -g corepack@latest --force | |
| corepack enable | |
| - uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v3.0.2 | |
| id: changes | |
| with: | |
| predicate-quantifier: 'every' | |
| filters: | | |
| changed: | |
| - "!**/*.md" | |
| - "!**/*.mdx" | |
| - "!**/_meta.json" | |
| - "!**/dictionary.txt" | |
| - name: Setup Node.js | |
| if: steps.changes.outputs.changed == 'true' | |
| uses: actions/setup-node@2028fbc5c25fe9cf00d9f06a71cc4710d4507903 # v6.0.0 | |
| with: | |
| node-version: '22.20' | |
| package-manager-cache: false | |
| - name: Install Dependencies | |
| if: steps.changes.outputs.changed == 'true' | |
| run: pnpm install && cd ./e2e && pnpm run setup | |
| - name: E2E Test - 1 | |
| if: steps.changes.outputs.changed == 'true' | |
| run: pnpm run e2e:webpack --shard=1/2 | |
| - name: E2E Test - 2 | |
| if: steps.changes.outputs.changed == 'true' | |
| run: pnpm run e2e:webpack --shard=2/2 |