[Repo Assist] test: add ToMd table alignment and InlineHtmlBlock tests#1187
Draft
github-actions[bot] wants to merge 2 commits intomainfrom
Draft
[Repo Assist] test: add ToMd table alignment and InlineHtmlBlock tests#1187github-actions[bot] wants to merge 2 commits intomainfrom
github-actions[bot] wants to merge 2 commits intomainfrom
Conversation
Add 7 unit tests to Markdown.fs covering previously untested cases in Markdown.ToMd serialisation: - 4 tests for table column alignment markers: left (:---), center (:---:), right (---:), and default (---) are all correctly emitted. - 1 test for mixed alignments in a single table. - 2 tests for InlineHtmlBlock round-trip: verifies that raw HTML blocks in a document are preserved unchanged by ToMd. All 352 Markdown tests pass. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This was referenced Apr 26, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 This PR was created by Repo Assist, an automated AI assistant.
Summary
Adds 7 unit tests to
Markdown.fscovering previously untested cases inMarkdown.ToMdserialisation:Table column alignment (5 tests)
The
formatParagraphhandler forTableBlockmaps eachMarkdownColumnAlignmentcase to a marker string —:---(left),:---:(centre),---:(right),---(default) — but none of these paths had test coverage. The new tests verify all four individually, plus a mixed-alignment table.Inline HTML block (2 tests)
InlineHtmlBlockis handled byformatParagraph(the lines of raw HTML are emitted verbatim), but there were no tests for this path. The new tests verify that a multi-line<div>block round-trips throughToMdwithout corruption.Changes
tests/FSharp.Markdown.Tests/Markdown.fs— 7 new[<Test>]functionsTest Status
✅
dotnet build FSharp.Formatting.sln --configuration Release— 0 errors, 0 warnings✅
dotnet test tests/FSharp.Markdown.Tests --configuration Release --no-build— 352/352 passed (includes 7 new tests, up from 345)