Skip to content

Commit 6fcc4d0

Browse files
chore(ci): relax codecov patch check to 85% floor + informational
Codecov was set to target: auto with a 1% threshold on both project and patch, so every PR had to stay within 1% of the current ~95% project coverage. That ratchets tighter each time new easily-tested code is added, and penalises PRs that touch editor-window callbacks or polling loops which are not cleanly unit-testable. Switch to a fixed 85% floor with 2% threshold on both checks, and mark the patch check informational so the Codecov comment still surfaces dropped lines (useful for review) but does not block merge. The project check still guards against real regressions. Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com> Signed-off-by: JasonXuDeveloper - 傑 <jason@xgamedev.net>
1 parent 96c010f commit 6fcc4d0

1 file changed

Lines changed: 15 additions & 4 deletions

File tree

codecov.yml

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,23 @@ coverage:
55
status:
66
project:
77
default:
8-
target: auto
9-
threshold: 1%
8+
# Floor at 85% so normal drift (a few hard-to-unit-test editor paths)
9+
# does not fail the check. Base project is ~95%, so there is plenty of
10+
# headroom without ratcheting it tighter on every PR.
11+
target: 85%
12+
threshold: 2%
1013
patch:
1114
default:
12-
target: auto
13-
threshold: 1%
15+
# Same 85% floor for added/changed lines. Editor-window callbacks
16+
# (OnFocus, polling schedule) are not cleanly unit-testable, so we
17+
# accept a handful of uncovered lines per PR instead of chasing
18+
# auto-vs-base noise.
19+
target: 85%
20+
threshold: 2%
21+
# Informational: show the comment (so reviewers see where coverage
22+
# dropped) but never block the merge. The project check above still
23+
# guards against real regressions.
24+
informational: true
1425

1526
# Fix Docker container path prefix in coverage reports
1627
# Unity test runner generates paths like /github/workspace/UnityProject/...

0 commit comments

Comments
 (0)