File tree Expand file tree Collapse file tree 1 file changed +21
-2
lines changed Expand file tree Collapse file tree 1 file changed +21
-2
lines changed Original file line number Diff line number Diff line change 2424 with :
2525 hugo-version : ' 0.147.8'
2626 extended : true
27- - name : Install dependencies and playwright browsers
28- run : cd tests && npm ci && npx playwright install --with-deps
27+ - name : Install dependencies
28+ run : cd tests && npm ci
29+ - name : Check playwright version
30+ id : check-playwright-version
31+ run : |
32+ version=$(npm list @playwright/test --json | jq -r '.dependencies["@playwright/test"].version')
33+ echo "version=$version" >> $GITHUB_OUTPUT
34+ echo "Version:" $version
35+ - name : Attempt to restore cache
36+ uses : actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830 # v4.3.0
37+ id : restore-cache
38+ with :
39+ # By default this path is hardcoded by OS - https://playwright.dev/python/docs/browsers#managing-browser-binaries
40+ path : ' ~/.cache/ms-playwright'
41+ key : ' ${{ runner.os }}-playwright-${{ steps.check-playwright-version.outputs.version }}'
42+ # Fallback, if version changed, use the most recent cached version.
43+ restore-keys : |
44+ ${{ runner.os }}-playwright-
45+ - name : Install playwright dependencies
46+ if : steps.restore-cache.outputs.cache-hit != 'true'
47+ run : cd tests && npx playwright install --with-deps
2948 - name : Run Playwright tests
3049 id : test-ui
3150 run : |
You can’t perform that action at this time.
0 commit comments