Skip to content

[Repo Assist] test: add ToMd table alignment and InlineHtmlBlock tests#1187

Draft
github-actions[bot] wants to merge 2 commits intomainfrom
repo-assist/test-tomd-table-html-2026-04-24-4780fc0504066a65
Draft

[Repo Assist] test: add ToMd table alignment and InlineHtmlBlock tests#1187
github-actions[bot] wants to merge 2 commits intomainfrom
repo-assist/test-tomd-table-html-2026-04-24-4780fc0504066a65

Conversation

@github-actions
Copy link
Copy Markdown
Contributor

🤖 This PR was created by Repo Assist, an automated AI assistant.

Summary

Adds 7 unit tests to Markdown.fs covering previously untested cases in Markdown.ToMd serialisation:

Table column alignment (5 tests)

The formatParagraph handler for TableBlock maps each MarkdownColumnAlignment case 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)

InlineHtmlBlock is handled by formatParagraph (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 through ToMd without corruption.

Changes

  • tests/FSharp.Markdown.Tests/Markdown.fs — 7 new [<Test>] functions

Test Status

dotnet build FSharp.Formatting.sln --configuration Release — 0 errors, 0 warnings
dotnet test tests/FSharp.Markdown.Tests --configuration Release --no-build352/352 passed (includes 7 new tests, up from 345)

Generated by 🌈 Repo Assist, see workflow run. Learn more.

Generated by 🌈 Repo Assist, see workflow run. Learn more.

To install this agentic workflow, run

gh aw add githubnext/agentics/workflows/repo-assist.md@96b9d4c39aa22359c0b38265927eadb31dcf4e2a

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>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants