• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

umputun / revdiff / 24852781334
90%

Build:
DEFAULT BRANCH: master
Ran 23 Apr 2026 06:48PM UTC
Jobs 1
Files 59
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

23 Apr 2026 06:47PM UTC coverage: 89.355% (-0.2%) from 89.581%
24852781334

push

github

web-flow
feat(diff): line-count labels on compact-mode dividers (⋯ N lines ⋯) (#146)

* feat(diff): show line count in between-hunk and leading dividers

parser computes the gap from hunk-header metadata and renders it as
"⋯ N lines ⋯" (midline horizontal ellipsis). previously dividers were
a static "...".

uses prevOldEnd tracked via parsed hunk lengths rather than oldNum, so
insertion-only hunks (@@ -K,0 ...) compute correctly — oldNum does not
advance on `+` body lines. max(oldLen, 1) handles both omitted-length
(git implicit 1) and literal-zero cases. leading divider appears when
the first hunk starts after line 1; trailing divider is out of scope
(needs total file-line count threaded through Renderer).

Related to #145

* feat(diff): add trailing divider showing lines after last hunk

parseUnifiedDiff now accepts totalOldLines and emits a "⋯ N lines ⋯"
divider at the end when the last hunk does not reach EOF. each VCS
implementation (git/hg/jj) computes the pre-change file's line count
via git show / hg cat / jj file show against the resolved old-ref
(range ref left operand, single ref, or sensible default).

extracts appendGapDivider helper to unify leading / between-hunks /
trailing emission — same "⋯ N lines ⋯" format, different gap source.

test callers updated to pass 0 (unknown total, skip trailing). 6 new
parser-level tests cover trailing plural / singular / no-trailing /
unknown-total / leading+between+trailing / empty-diff cases.

Related to #145

* fix(diff): address code review findings for divider work

- git totalOldLines: check "..." before ".." in ref splitting so A...B
  takes left operand A (not "A" + ".B"). triple-dot ranges still show
  the left operand of the range rather than merge-base, which is
  approximate but matches hg/jj behavior.
- gate totalOldLines subprocess behind compact mode in all VCS impls;
  full-file mode always reaches EOF so the trailing-divider probe was
  a wasted subprocess (~2× process launches per FileDiff cal... (continued)

75 of 107 new or added lines in 3 files covered. (70.09%)

8251 of 9234 relevant lines covered (89.35%)

454.07 hits per line

Uncovered Changes

Lines Coverage ∆ File
24
72.73
-7.27% app/diff/jj.go
6
90.72
-2.34% app/diff/hg.go
2
92.23
0.59% app/diff/diff.go
Jobs
ID Job ID Ran Files Coverage
1 24852781334.1 23 Apr 2026 06:48PM UTC 59
89.35
GitHub Action Run
Source Files on build 24852781334
  • Tree
  • List 59
  • Changed 3
  • Source Changed 0
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • 0435ac30 on github
  • Prev Build on master (#24826206221)
  • Next Build on master (#24853930802)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc