From b03462066ecc05817a5a1a2c10df8c830e0cdcb2 Mon Sep 17 00:00:00 2001 From: Jacob Hagstedt Date: Mon, 14 Sep 2026 18:54:56 +0200 Subject: [PATCH] Ratchet coverage floors up to match measured coverage Frontend floors move to 96/96/91/92 (measured 97.27/97.27/92.87/93.78) and the backend gate to 80 (measured 83.47). Kept 1-2pp below measured so real regressions fail without false positives on incidental drift. These are a ratchet: raised as coverage grows, never lowered to make a gate pass. Co-Authored-By: Claude Opus 5 Claude-Session: https://claude.ai/code/session_01RXMhc9nT6sNz1SL4j8dznL --- .github/workflows/ci.yml | 2 +- frontend/vitest.config.ts | 11 +++++------ todo.md | 5 +++++ 3 files changed, 11 insertions(+), 7 deletions(-) create mode 100644 todo.md diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ed3adc2..43195c3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -34,7 +34,7 @@ jobs: - name: Test with coverage # Measured ~81%; set threshold 1-2pp below to catch regressions. - run: uv run pytest --cov=app --cov-report=term-missing --cov-fail-under=75 + run: uv run pytest --cov=app --cov-report=term-missing --cov-fail-under=80 # --------------------------------------------------------------------------- # Frontend: ESLint + Vitest with 90% coverage gate diff --git a/frontend/vitest.config.ts b/frontend/vitest.config.ts index 92e9115..1f1d049 100644 --- a/frontend/vitest.config.ts +++ b/frontend/vitest.config.ts @@ -17,14 +17,13 @@ export default defineConfig({ provider: 'v8', reporter: ['text', 'lcov'], // Thresholds set as a regression ratchet to prevent coverage from dropping. - // Measured: lines 96.52%, functions 91.08%, statements 96.52%, branches 86.78%. + // Measured: lines 97.27%, functions 92.87%, statements 97.27%, branches 93.78%. // Set ~1-2pp below measured to catch real regressions without false positives. - // Branches set conservatively (85) as it's the weakest metric. thresholds: { - lines: 95, - functions: 89, - branches: 85, - statements: 95, + lines: 96, + functions: 91, + branches: 92, + statements: 96, }, include: ['src/**/*.{ts,tsx}'], exclude: [ diff --git a/todo.md b/todo.md new file mode 100644 index 0000000..0eebfed --- /dev/null +++ b/todo.md @@ -0,0 +1,5 @@ +- [x] In planning tab: It is very annoying that I need to click "save" on each individual thing. + Better if we auto-save this (with a debounce). + DONE — per-row Save button removed; edits auto-save 800ms after the last change, with a + per-row "Sparar…"/"Sparat" status. Also fixed the underlying Plan-page bug where every + mutation swapped the page for a spinner and collapsed the expanded row.