diff --git a/.github/workflows/compiler_playground.yml b/.github/workflows/compiler_playground.yml index 2ef9920c26dda..224c82e6de7c3 100644 --- a/.github/workflows/compiler_playground.yml +++ b/.github/workflows/compiler_playground.yml @@ -40,7 +40,19 @@ jobs: **/node_modules key: compiler-node_modules-v6-${{ runner.arch }}-${{ runner.os }}-${{ hashFiles('compiler/**/yarn.lock') }} - run: yarn install --frozen-lockfile + - name: Check Playwright version + id: playwright_version + run: echo "playwright_version=$(npm ls @playwright/test | grep @playwright | sed 's/.*@//' | head -1)" >> "$GITHUB_OUTPUT" + - name: Cache Playwright Browsers for version ${{ steps.playwright_version.outputs.playwright_version }} + id: cache_playwright_browsers + uses: actions/cache@v4 + with: + path: ~/.cache/ms-playwright + key: playwright-browsers-v6-${{ runner.arch }}-${{ runner.os }}-${{ steps.playwright_version.outputs.playwright_version }} - run: npx playwright install --with-deps chromium + if: steps.cache_playwright_browsers.outputs.cache-hit != 'true' + - run: npx playwright install-deps + if: steps.cache_playwright_browsers.outputs.cache-hit == 'true' - run: CI=true yarn test - run: ls -R test-results if: '!cancelled()' diff --git a/.github/workflows/runtime_build_and_test.yml b/.github/workflows/runtime_build_and_test.yml index 303ef92b6e3b5..165ddac43cd29 100644 --- a/.github/workflows/runtime_build_and_test.yml +++ b/.github/workflows/runtime_build_and_test.yml @@ -599,13 +599,10 @@ jobs: if: steps.node_modules.outputs.cache-hit != 'true' - run: yarn --cwd fixtures/flight install --frozen-lockfile if: steps.node_modules.outputs.cache-hit != 'true' - - name: Store Playwright version + - name: Check Playwright version id: playwright_version - run: | - PLAYWRIGHT_VERSION=$(npm ls @playwright/test | grep @playwright | sed 's/.*@//') - echo "Playwright's Version: $PLAYWRIGHT_VERSION" - echo "playwright_version=$PLAYWRIGHT_VERSION" >> "$GITHUB_OUTPUT" - - name: Cache Playwright Browsers for Playwright's Version + run: echo "playwright_version=$(npm ls @playwright/test | grep @playwright | sed 's/.*@//' | head -1)" >> "$GITHUB_OUTPUT" + - name: Cache Playwright Browsers for version ${{ steps.playwright_version.outputs.playwright_version }} id: cache_playwright_browsers uses: actions/cache@v4 with: