mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-11-24 13:37:34 +03:00
feat: cache playwright binaries in GHA
This commit is contained in:
parent
90185976ca
commit
17ad204a37
15
.github/workflows/test-e2e.yml
vendored
15
.github/workflows/test-e2e.yml
vendored
@ -25,8 +25,19 @@ jobs:
|
||||
pnpm-lock.yaml
|
||||
- name: Install dependencies
|
||||
run: pnpm install
|
||||
- name: Get installed Playwright version
|
||||
id: playwright-version
|
||||
run: echo "PLAYWRIGHT_VERSION=$(node -e "console.log(require('./package-lock.json').dependencies['@playwright/test'].version)")" >> $GITHUB_ENV
|
||||
- name: Cache playwright binaries
|
||||
uses: actions/cache@v4
|
||||
id: playwright-cache
|
||||
with:
|
||||
path: |
|
||||
~/.cache/ms-playwright
|
||||
key: ${{ runner.os }}-playwright-${{ env.PLAYWRIGHT_VERSION }}
|
||||
- name: Install Playwright Browsers
|
||||
run: pnpm dlx playwright@1.40.0 install --with-deps chromium
|
||||
if: steps.playwright-cache.outputs.cache-hit != 'true'
|
||||
run: pnpm dlx "playwright@$PLAYWRIGHT_VERSION" install --with-deps chromium
|
||||
- name: Run Tests
|
||||
run: cd app && pnpm test:e2e
|
||||
env:
|
||||
@ -36,6 +47,6 @@ jobs:
|
||||
if: ${{ !cancelled() }}
|
||||
with:
|
||||
name: playwright-report
|
||||
path: app/test-results/
|
||||
path: app/test-results/**/trace.zip
|
||||
if-no-files-found: ignore
|
||||
retention-days: 30
|
||||
|
Loading…
Reference in New Issue
Block a user