reduce comment

This commit is contained in:
Jinjing
2026-08-07 09:48:10 -07:00
parent 2d8dc63eb0
commit e4e5d39b29
2 changed files with 4 additions and 19 deletions
+2 -9
View File
@@ -59,15 +59,8 @@ export type GitBranchLineTotal = {
added: number
removed: number
mergeBase: string
/**
* Disjoint subsets of `added`/`removed`, by path heuristic. Generated is
* classified first, so a snapshot counts as generated rather than as test.
* Whatever neither claims is hand-written source.
*
* Absent from hosts that predate the split, which reads as "not known" — not
* zero. The two fields ship together, but read them independently: a host
* could gain one before the other.
*/
// Path-heuristic buckets of added/removed; generated wins on overlap. Optional
// for pre-split hosts (absent = unknown, not zero).
test?: { added: number; removed: number }
generated?: { added: number; removed: number }
}
+2 -10
View File
@@ -1,13 +1,5 @@
/**
* Path-only heuristic for "is this test code?", used to split line totals into a
* test and a non-test half. Deliberately conservative: a miss understates the
* test share, a false positive overstates it, and neither is worth reading file
* contents on every status pass.
*
* Runs once per changed file inside the branch-total sum, so both patterns are
* anchored and match the raw path directly — no lowercasing, splitting or
* substring allocation per file.
*/
// Path-only test heuristic for branch line-total buckets. Conservative and
// anchored on the raw path (no lowercasing/splitting per file).
// Whole path segments only, so `src/latest/x.ts` and `contest/` don't count.
// The trailing separator is what keeps a *file* named `test.ts` out of here.