private void RunTest(string input, string expected, Action <MantisLinkOptions> setup)
        {
            // arrange
            MarkdownPipeline  target;
            MantisLinkOptions options;
            string            actual;

            options = new MantisLinkOptions("https://issues.example.com/");
            setup?.Invoke(options);

            target = new MarkdownPipelineBuilder().UseMantisLinks(options).Build();

            expected = "<p>" + expected + "</p>\n";

            // act
            actual = Markdown.ToHtml(input, target);

            // assert
            Assert.AreEqual(expected, actual);
        }
        public void Text_renderering_test()
        {
            // arrange
            MantisLinkRenderer target;
            MantisLinkOptions  options;
            MantisLink         link;
            TextWriter         writer;
            HtmlRenderer       renderer;
            string             expected;
            string             actual;

            // TODO: There's got to be an easier of testing plain text output

            expected = "#1338";

            writer   = new StringWriter();
            renderer = new HtmlRenderer(writer)
            {
                EnableHtmlForInline = false
            };

            options = new MantisLinkOptions("https://issues.example.com/");
            target  = new MantisLinkRenderer(options);

            link = new MantisLink
            {
                IssueNumber = new StringSlice("1338", 0, 3)
            };

            // act
            target.Write(renderer, link);

            // assert
            actual = writer.ToString();
            Assert.AreEqual(expected, actual);
        }