mirror of
https://github.com/gitbutlerapp/gitbutler.git
synced 2024-11-28 04:47:42 +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
|
pnpm-lock.yaml
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: pnpm install
|
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
|
- 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
|
- name: Run Tests
|
||||||
run: cd app && pnpm test:e2e
|
run: cd app && pnpm test:e2e
|
||||||
env:
|
env:
|
||||||
@ -36,6 +47,6 @@ jobs:
|
|||||||
if: ${{ !cancelled() }}
|
if: ${{ !cancelled() }}
|
||||||
with:
|
with:
|
||||||
name: playwright-report
|
name: playwright-report
|
||||||
path: app/test-results/
|
path: app/test-results/**/trace.zip
|
||||||
if-no-files-found: ignore
|
if-no-files-found: ignore
|
||||||
retention-days: 30
|
retention-days: 30
|
||||||
|
Loading…
Reference in New Issue
Block a user