File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1919 node-version : 16
2020 cache : " pnpm"
2121 - run : pnpm install
22+
23+ # https://github.com/vitejs/vite/blob/main/.github/workflows/ci.yml#L62
24+ # Install playwright's binary under custom directory to cache
25+ - name : Set Playwright path (non-windows)
26+ if : runner.os != 'Windows'
27+ run : echo "PLAYWRIGHT_BROWSERS_PATH=$HOME/.cache/playwright-bin" >> $GITHUB_ENV
28+ - name : Set Playwright path (windows)
29+ if : runner.os == 'Windows'
30+ run : echo "PLAYWRIGHT_BROWSERS_PATH=$HOME\.cache\playwright-bin" >> $env:GITHUB_ENV
31+
32+ - name : Cache Playwright's binary
33+ uses : actions/cache@v3
34+ with :
35+ # Playwright removes unused browsers automatically
36+ # So does not need to add playwright version to key
37+ key : ${{ runner.os }}-playwright-bin-v1
38+ path : ${{ env.PLAYWRIGHT_BROWSERS_PATH }}
39+
40+ - name : Install Playwright
41+ # does not need to explicitly set chromium after https://github.com/microsoft/playwright/issues/14862 is solved
42+ run : pnpm playwright install chromium
43+
2244 - run : pnpm dev:prepare
2345 - run : pnpm lint
2446 - run : pnpm test
You can’t perform that action at this time.
0 commit comments