Skip to content

Re-enable fmt's test that a blank line after a comment is kept - #40

Merged
david-Darkcollective merged 1 commit into
developfrom
fix/fmt-blank-after-comment
Oct 9, 2026
Merged

david-Darkcollective merged 1 commit into
developfrom
fix/fmt-blank-after-comment

Conversation

@david-Darkcollective

Copy link
Copy Markdown
Member

Re-enables FmtTest.Layout.blankAfterComment, disabled since #37 because the engine's printer dropped a blank line between a comment and the statement or namespace after it.

Needs DarkCollective/relix-core#108 in the snapshot first. That PR fixes DarkCollective/relix-core#107. Until it's published, this test fails in CI.

The test formats -- header, a blank line, namespace demo;, then -- about N, a blank line, query N;, and expects the text back unchanged. Against a local build of relix-core#108 the whole suite passes; against the current snapshot this test fails, as it should.

No code changes: fmt prints with the engine's ScriptPrinter, so the fix arrives with the engine.

DarkCollective/relix-core#107 made the engine's printer keep a blank line
between a comment and the statement or namespace after it, so
FmtTest.Layout.blankAfterComment runs again: "-- header", a blank line,
"namespace demo;", then a comment set apart from its query the same way,
format to themselves.
@david-Darkcollective
david-Darkcollective merged commit 237dd83 into develop Oct 9, 2026
3 of 9 checks passed
@david-Darkcollective
david-Darkcollective deleted the fix/fmt-blank-after-comment branch October 9, 2026 20:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant