From 209da9e628112a5a25ac4519370cfdc072462547 Mon Sep 17 00:00:00 2001 From: Peter Stone Date: Mon, 24 Aug 2026 07:58:47 +0000 Subject: Let filter rules be scoped to one feed; fix coverage-gate report path bug The data model and FilterRuleEngine already supported a per-feed scope (FilterRuleEntity.feedId), but Settings' "Add rule" form never let a user set it -- only a hardcoded migration had ever created one. Add a FeedScopePicker so a rule can target "All feeds" (unchanged default) or one specific feed, and show each existing rule's scope in the list. Added the first real unit tests in this repo (FilterRuleEngineTest), covering global vs. feed-scoped matching and mute-wins-over-highlight priority -- the exact behavior this UI gap left unexercised outside one migration-seeded row. First real jacoco coverage number: 2.31%. While verifying, found the pre-commit hook's coverage step was silently a no-op: it pointed at app/build/reports/jacoco/report.xml, but the jacoco setup that landed here uses the standard Gradle JacocoReport task, which writes to reports/jacoco/jacocoTestReport/jacocoTestReport.xml instead. Fixed the path so the gate actually reads real numbers now. Co-Authored-By: Claude Sonnet 5 Claude-Session: https://claude.ai/code/session_017GMEkHeqKz6FLkmizowBTK --- .githooks/pre-commit | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to '.githooks/pre-commit') diff --git a/.githooks/pre-commit b/.githooks/pre-commit index 389280a..32b492a 100755 --- a/.githooks/pre-commit +++ b/.githooks/pre-commit @@ -27,7 +27,7 @@ fi echo "== [5/8] Coverage must not decrease ==" ./gradlew :app:jacocoTestReport -q -REPORT="app/build/reports/jacoco/report.xml" +REPORT="app/build/reports/jacoco/jacocoTestReport/jacocoTestReport.xml" BASELINE_FILE=".coverage-baseline" if [ -f "$REPORT" ]; then CURRENT=$(python3 - "$REPORT" <<'PY' -- cgit v1.2.3