Refactor export to streaming sessions #26
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| # PR-level continuous integration: dependency audit, architecture, lint, | |
| # formatting, build, tests, coverage and benchmark smoke checks, plus the Rust | |
| # audit/test/clippy/fmt gates. Runs on | |
| # every push to master and every pull request so a regression is caught before | |
| # merge. (The tag-triggered cross-platform release build lives in release.yml.) | |
| on: | |
| push: | |
| branches: [master] | |
| pull_request: | |
| jobs: | |
| frontend: | |
| name: Frontend (audit + architecture + quality + coverage) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v5 | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v5 | |
| # Version is read from packageManager field in package.json (pnpm@11.5.3). | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v5 | |
| with: | |
| node-version: 22 | |
| cache: pnpm | |
| - name: Install frontend dependencies | |
| run: pnpm install --frozen-lockfile | |
| - name: Dependency audit (moderate and above) | |
| run: pnpm audit --audit-level moderate | |
| - name: Lint | |
| run: pnpm run lint | |
| - name: Format check | |
| run: pnpm run format:check | |
| - name: Architecture boundaries and cycles | |
| run: pnpm run architecture | |
| - name: Type-check + build | |
| run: pnpm run build | |
| - name: Frontend tests | |
| run: pnpm run test:frontend | |
| # Benchmark smoke run: executes every bench (so a broken bench is caught) | |
| # and applies the 15% regression gate against any committed baseline. | |
| # The baseline is machine-local (gitignored), so on CI this currently | |
| # validates that the benches run cleanly without gating; a committed | |
| # baseline would activate the regression gate. | |
| - name: Benchmark smoke run | |
| run: pnpm run bench:frontend | |
| # Coverage gate: c8 enforces the configured line/branch/function | |
| # thresholds from .c8rc.json. Fails the job if coverage drops below them. | |
| - name: Coverage gate (overall >=85%) | |
| run: pnpm run coverage:frontend | |
| # Per-domain coverage gate: lib/ files must each meet >=90% line | |
| # coverage (composables excluded — their onMounted/listen() lifecycle hooks | |
| # are structurally unreachable in the headless test runner). | |
| - name: Coverage gate (lib/ per-file >=90%) | |
| run: pnpm run coverage:lib | |
| rust: | |
| name: Rust (audit + fmt + clippy + test) | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v5 | |
| - name: Install Linux dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y libwebkit2gtk-4.1-dev libayatana-appindicator3-dev librsvg2-dev patchelf libudev-dev | |
| - name: Setup Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: clippy, rustfmt | |
| - name: Setup Rust cache | |
| uses: Swatinem/rust-cache@v2 | |
| with: | |
| workspaces: src-tauri | |
| - name: Install Rust advisory scanner | |
| run: cargo install cargo-audit --locked | |
| - name: Rust dependency audit | |
| run: cargo audit | |
| - name: Format check | |
| run: cargo fmt --manifest-path src-tauri/Cargo.toml -- --check | |
| - name: Clippy (deny warnings on changed code paths) | |
| run: cargo clippy --manifest-path src-tauri/Cargo.toml --workspace --all-targets --locked -- -D warnings | |
| - name: Rust tests | |
| run: cargo test --manifest-path src-tauri/Cargo.toml --workspace --locked | |
| # Rust coverage report: cargo-tarpaulin runs only on Linux. Reported | |
| # as a build artifact; not yet a hard gate (no committed threshold), but | |
| # surfaces coverage drift on the Rust side alongside the frontend c8 gate. | |
| - name: Rust coverage report (tarpaulin) | |
| run: | | |
| cargo install cargo-tarpaulin --locked || true | |
| cargo tarpaulin --manifest-path src-tauri/Cargo.toml --workspace --out Html --output-dir coverage/rust || true | |
| continue-on-error: true |