Skip to content

Commit b11d0a3

Browse files
committed
plan 86: align test comment with ascending applyEdits pass
Address PR #169 review nit: TestRuleFixMultipleFeaturesOnOneLine's doc comment described "reverse-order edit application", which was true of the prior implementation. applyEdits now sorts edits in ascending start order and builds the output in a single forward pass, so update the comment to match.
1 parent 8f916c7 commit b11d0a3

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

internal/rules/markdownflavor/fix_test.go

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,9 +109,10 @@ func TestRuleFixBareURLGFMAccepts(t *testing.T) {
109109

110110
// --- combined -----------------------------------------------------------
111111

112-
// TestRuleFixMultipleFeaturesOnOneLine covers reverse-order edit
113-
// application: two byte-range edits on the same line must compose
114-
// without one corrupting the other's offsets.
112+
// TestRuleFixMultipleFeaturesOnOneLine covers the ascending single-
113+
// pass build in applyEdits: two byte-range edits on the same line
114+
// must compose into a contiguous output without one corrupting the
115+
// other's spans.
115116
func TestRuleFixMultipleFeaturesOnOneLine(t *testing.T) {
116117
got := fixWith(t, "commonmark",
117118
"# Heading {#top}\n\nText ~~old~~ at https://example.com.\n")

0 commit comments

Comments
 (0)