Skip to content

v3: offline-first architecture, per-account local data, stable app shell #276

v3: offline-first architecture, per-account local data, stable app shell

v3: offline-first architecture, per-account local data, stable app shell #276

Workflow file for this run

name: CI
on:
pull_request:
branches: [master]
push:
branches: [master]
jobs:
lint:
name: Biome Check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
- run: npm ci
- run: npm run lint
test:
name: Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
- run: npm ci
- run: npm test
e2e:
name: E2E (Playwright + armadietto)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 22
cache: npm
- run: npm ci
- name: Start armadietto
# Real-backend e2e: bring up the local remoteStorage server the
# suite talks to. The image build is small (node:20-alpine +
# `npm i -g armadietto`) and Docker layer caching keeps reruns
# cheap. The fixture's `waitForArmadietto` polls the HTTP root
# before the first test, so no explicit health-check step here.
run: docker compose up -d
- name: Resolve Playwright version
id: pw-version
run: |
echo "version=$(node -p "require('@playwright/test/package.json').version")" >> "$GITHUB_OUTPUT"
- name: Cache Playwright browsers
id: pw-cache
uses: actions/cache@v4
with:
path: ~/.cache/ms-playwright
key: playwright-${{ runner.os }}-${{ steps.pw-version.outputs.version }}-chromium
- name: Install Playwright browsers
if: steps.pw-cache.outputs.cache-hit != 'true'
run: npx playwright install --with-deps chromium
- name: Install Playwright system deps
# Cached browsers don't include OS-level deps (libnss3, etc.), so we
# still need the deps step on a cache hit.
if: steps.pw-cache.outputs.cache-hit == 'true'
run: npx playwright install-deps chromium
- name: Run smoke tests (chromium only)
# PRs run the @smoke subset (~20 tests) on Chromium only.
# The full suite (both browsers) runs as a release pre-flight in release.yml.
run: npm run test:e2e:smoke
- name: Upload Playwright report on failure
if: failure()
uses: actions/upload-artifact@v4
with:
name: playwright-report
path: playwright-report/
retention-days: 14
- name: Upload test-results on failure
if: failure()
uses: actions/upload-artifact@v4
with:
name: test-results
path: test-results/
retention-days: 14
- name: Capture armadietto logs on failure
if: failure()
run: docker compose logs armadietto > armadietto.log 2>&1 || true
- name: Upload armadietto logs on failure
if: failure()
uses: actions/upload-artifact@v4
with:
name: armadietto-logs
path: armadietto.log
retention-days: 14
- name: Stop armadietto
if: always()
run: docker compose down