[PR #389] [MERGED] Improve code coverage #981

Open
opened 2026-01-29 14:48:06 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/xoofx/markdig/pull/389
Author: @MihaZupan
Created: 1/22/2020
Status: Merged
Merged: 1/26/2020
Merged by: @xoofx

Base: masterHead: code-coverage


📝 Commits (9)

  • f401d50 Add SmartyPants tests
  • d18487a Fix StringLineGroupIterator.PeekChar for cross-line peeks
  • 1252e49 Add more custom emoji tests
  • 754d11f Fix test execution inside VS Enterprise Live Unit Testing
  • d2c89a3 Add tests for core Markdown apis
  • 655bf13 Exclude CompactPrefixTree from code coverage
  • 99b250b Add ContainerBlock tests
  • 3f50b3f Add LinkHelper.UrilizeAsGfm tests
  • 71c6803 Make ExcludeFromCodeCoverage compatibility stub internal

📊 Changes

15 files changed (+377 additions, -15 deletions)

View changed files

src/Markdig.Tests/TestContainerBlocks.cs (+70 -0)
📝 src/Markdig.Tests/TestCustomEmojis.cs (+30 -0)
📝 src/Markdig.Tests/TestLinkHelper.cs (+10 -0)
src/Markdig.Tests/TestMarkdigCoreApi.cs (+148 -0)
📝 src/Markdig.Tests/TestParser.cs (+7 -0)
src/Markdig.Tests/TestSmartyPants.cs (+36 -0)
📝 src/Markdig.Tests/TestStringSliceList.cs (+29 -0)
📝 src/Markdig/Extensions/Emoji/EmojiMapping.cs (+4 -4)
📝 src/Markdig/Helpers/CompactPrefixTree.cs (+2 -0)
src/Markdig/Helpers/ExcludeFromCodeCoverageAttribute.cs (+12 -0)
📝 src/Markdig/Helpers/LinkHelper.cs (+3 -5)
📝 src/Markdig/Helpers/StringLineGroup.cs (+19 -4)
📝 src/Markdig/Helpers/ThrowHelper.cs (+2 -0)
📝 src/Markdig/Syntax/ContainerBlock.cs (+4 -0)
📝 src/Markdig/Syntax/SourceSpan.cs (+1 -2)

📄 Description

Add some tests and fix a few details that those tests uncovered.

I think I can push coverage to ~98% with reasonable tests like this, the rest would be catching every edge-case handling logic.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/xoofx/markdig/pull/389 **Author:** [@MihaZupan](https://github.com/MihaZupan) **Created:** 1/22/2020 **Status:** ✅ Merged **Merged:** 1/26/2020 **Merged by:** [@xoofx](https://github.com/xoofx) **Base:** `master` ← **Head:** `code-coverage` --- ### 📝 Commits (9) - [`f401d50`](https://github.com/xoofx/markdig/commit/f401d5082e1685f3715db0c5d733fa7a24927790) Add SmartyPants tests - [`d18487a`](https://github.com/xoofx/markdig/commit/d18487ae53c7567f73dd42f8409d14a88ec8178b) Fix StringLineGroupIterator.PeekChar for cross-line peeks - [`1252e49`](https://github.com/xoofx/markdig/commit/1252e49ba482e896e6f6c4bdbeb0d12554cc75b0) Add more custom emoji tests - [`754d11f`](https://github.com/xoofx/markdig/commit/754d11fd444d1ab4a2aeb7774390e8f1e53014e5) Fix test execution inside VS Enterprise Live Unit Testing - [`d2c89a3`](https://github.com/xoofx/markdig/commit/d2c89a3a066685be67da3fc2e07b7c9775998f6b) Add tests for core Markdown apis - [`655bf13`](https://github.com/xoofx/markdig/commit/655bf13df02def22ef58c487aced81d11aadf149) Exclude CompactPrefixTree from code coverage - [`99b250b`](https://github.com/xoofx/markdig/commit/99b250b4c978f8a87b8a5297e28e09eca82220d9) Add ContainerBlock tests - [`3f50b3f`](https://github.com/xoofx/markdig/commit/3f50b3fd0b1e84342fd1043dfc175e5e363dc3a3) Add LinkHelper.UrilizeAsGfm tests - [`71c6803`](https://github.com/xoofx/markdig/commit/71c680388c0e83ec5a3b5a3a4c7bf914bc844eb4) Make ExcludeFromCodeCoverage compatibility stub internal ### 📊 Changes **15 files changed** (+377 additions, -15 deletions) <details> <summary>View changed files</summary> ➕ `src/Markdig.Tests/TestContainerBlocks.cs` (+70 -0) 📝 `src/Markdig.Tests/TestCustomEmojis.cs` (+30 -0) 📝 `src/Markdig.Tests/TestLinkHelper.cs` (+10 -0) ➕ `src/Markdig.Tests/TestMarkdigCoreApi.cs` (+148 -0) 📝 `src/Markdig.Tests/TestParser.cs` (+7 -0) ➕ `src/Markdig.Tests/TestSmartyPants.cs` (+36 -0) 📝 `src/Markdig.Tests/TestStringSliceList.cs` (+29 -0) 📝 `src/Markdig/Extensions/Emoji/EmojiMapping.cs` (+4 -4) 📝 `src/Markdig/Helpers/CompactPrefixTree.cs` (+2 -0) ➕ `src/Markdig/Helpers/ExcludeFromCodeCoverageAttribute.cs` (+12 -0) 📝 `src/Markdig/Helpers/LinkHelper.cs` (+3 -5) 📝 `src/Markdig/Helpers/StringLineGroup.cs` (+19 -4) 📝 `src/Markdig/Helpers/ThrowHelper.cs` (+2 -0) 📝 `src/Markdig/Syntax/ContainerBlock.cs` (+4 -0) 📝 `src/Markdig/Syntax/SourceSpan.cs` (+1 -2) </details> ### 📄 Description Add some tests and fix a few details that those tests uncovered. I think I can push coverage to ~98% with reasonable tests like this, the rest would be catching every edge-case handling logic. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-29 14:48:06 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/markdig#981