From 8d23d8b1c3ea1d26ee9c649bd3b00da731fce187 Mon Sep 17 00:00:00 2001 From: yiling Date: Fri, 10 Jul 2026 19:28:14 +0800 Subject: [PATCH] fix(ci): split E2E tests into harness and app jobs --- .github/workflows/ci.yaml | 48 +++++++++++++++++++++++++++++++++++---- 1 file changed, 44 insertions(+), 4 deletions(-) diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 9d3b1daf..af0f74ee 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -57,7 +57,7 @@ jobs: bun run /tmp/shumai-local-release/node/node_modules/@shumai-one/shumai-transcode/bin/shumai-transcode-app.js --check e2e_video_player: - name: E2E (${{ matrix.project }}) + name: Harness E2E (${{ matrix.project }}) runs-on: ${{ matrix.os }} strategy: fail-fast: false @@ -86,13 +86,53 @@ jobs: - name: Install Playwright browser (${{ matrix.project }}) run: bunx playwright install --with-deps ${{ matrix.project }} - - name: Run video player e2e tests - run: bun run test:e2e --project=harness-${{ matrix.project }} --project=app-${{ matrix.project }} --no-deps + - name: Run video player harness tests + run: bun run test:e2e --project=harness-${{ matrix.project }} - name: Upload Playwright report if: ${{ !cancelled() }} uses: actions/upload-artifact@v4 with: - name: playwright-report-${{ matrix.project }} + name: playwright-report-harness-${{ matrix.project }} + path: playwright-report/ + retention-days: 7 + + e2e_app: + name: App E2E (${{ matrix.project }}) + runs-on: ${{ matrix.os }} + strategy: + fail-fast: false + matrix: + include: + - os: ubuntu-latest + project: chromium + - os: ubuntu-latest + project: firefox + # App E2E needs Docker for testcontainers, run webkit on Ubuntu + - os: ubuntu-latest + project: webkit + steps: + - name: Checkout + uses: actions/checkout@v4 + + - name: Setup Bun + uses: oven-sh/setup-bun@v1 + with: + bun-version: latest + + - name: Install dependencies + run: bun install + + - name: Install Playwright browser (${{ matrix.project }}) + run: bunx playwright install --with-deps ${{ matrix.project }} + + - name: Run app E2E tests + run: bun run test:e2e --project=app-${{ matrix.project }} --no-deps + + - name: Upload Playwright report + if: ${{ !cancelled() }} + uses: actions/upload-artifact@v4 + with: + name: playwright-report-app-${{ matrix.project }} path: playwright-report/ retention-days: 7