mirror of
https://github.com/Zakkaus/doona.git
synced 2026-12-06 16:01:00 +00:00
Every branch push ran the check twice, once for push and once for pull_request. Push now runs on main only. CI retries a failed e2e test once. A test that passes only on retry is reported as flaky and still fails the run, so a flake is told apart from a regression without being hidden.
47 lines
1.2 KiB
YAML
47 lines
1.2 KiB
YAML
name: Check
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
check:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
- uses: pnpm/action-setup@v4
|
|
- uses: actions/setup-node@v4
|
|
with:
|
|
node-version: 22
|
|
cache: pnpm
|
|
- run: pnpm install --frozen-lockfile
|
|
- run: pnpm check
|
|
- run: pnpm test:coverage
|
|
- uses: actions/upload-artifact@v4
|
|
with:
|
|
name: coverage
|
|
path: coverage/lcov.info
|
|
if-no-files-found: error
|
|
- run: pnpm build
|
|
- run: pnpm check:size
|
|
- name: Read Playwright version
|
|
id: playwright
|
|
run: echo "version=$(node -p "require('./package.json').devDependencies['@playwright/test']")" >> "$GITHUB_OUTPUT"
|
|
- uses: actions/cache@v4
|
|
with:
|
|
path: ~/.cache/ms-playwright
|
|
key: ${{ runner.os }}-playwright-${{ steps.playwright.outputs.version }}
|
|
- run: pnpm e2e:install --with-deps
|
|
- run: pnpm e2e
|
|
env:
|
|
DOONA_E2E_WEBKIT: '1'
|
|
- uses: actions/upload-artifact@v4
|
|
if: always()
|
|
with:
|
|
name: test-results
|
|
path: test-results/
|