feat: API endpoint tests, coverage target

- 8 new axum handler tests: health, stats, query-log, overrides CRUD,
  cache, blocking stats, services CRUD, dashboard HTML
- Tests use tower::oneshot — no network, no server startup
- test_ctx() builds minimal ServerCtx for isolated testing
- `make coverage` target (cargo-tarpaulin), separate from `make all`
- 82 total tests (was 74)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Razvan Dimescu
2026-03-28 02:44:57 +02:00
parent 6b8b401592
commit d63842996d
4 changed files with 257 additions and 1 deletions

View File

@@ -1,4 +1,4 @@
.PHONY: all build lint fmt check audit test bench clean deploy blog
.PHONY: all build lint fmt check audit test coverage bench clean deploy blog
all: lint build test
@@ -19,6 +19,9 @@ audit:
test:
cargo test
coverage:
cargo tarpaulin --skip-clean --out stdout
bench:
cargo bench