This repository has been archived on 2023-02-02. You can view files and clone it, but cannot push or open issues or pull requests.
mfgames-markdown-cil/tests/MfGames.Markdown.Gemtext.Tests/CodeInlineTests.cs

40 lines
1 KiB
C#

using Markdig;
using MfGames.Markdown.Gemtext.Extensions;
using MfGames.Markdown.Gemtext.Renderers;
using Xunit;
namespace MfGames.Markdown.Gemtext.Tests
{
public class CodeInlineTests
{
[Fact]
public void Default()
{
string input = "Normal `code` quote.";
string expected = "Normal code quote.";
string actual = MarkdownGemtext.ToGemtext(input);
Assert.Equal(expected, actual);
}
[Fact]
public void Normalized()
{
string input = "Normal `code` quote.";
string expected = "Normal `code` quote.";
string actual = MarkdownGemtext.ToGemtext(
input,
new MarkdownPipelineBuilder()
.Use(
new SetInlineFormatting
{
Code = InlineFormatting.Normalize,
})
.Build());
Assert.Equal(expected, actual);
}
}
}