Skip to content

Commit

Permalink
added a few more tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Zt-freak committed Apr 12, 2024
1 parent d5dc7d8 commit 3d415eb
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,11 @@ public void ItShould_MapFullDocument()

Mock<IXWPFTableRowMapper> tableRowMapperMock = new();
tableRowMapperMock
.Setup(t => t.MapDictionaryToRow(
It.IsAny<XWPFTableRow>(),
It.IsAny<IDictionary<string, object>>()
))
.Returns<XWPFTableRow, IDictionary<string, object>>((r, d) => r);
.Setup(t => t.MapDictionaryToRow(
It.IsAny<XWPFTableRow>(),
It.IsAny<IDictionary<string, object>>()
))
.Returns<XWPFTableRow, IDictionary<string, object>>((r, d) => r);
tableRowMapperMock
.Setup(t => t.MapEnumerableToRow(
It.IsAny<XWPFTableRow>(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,18 @@ public class MapParagraphTests
[Theory]
[InlineData("{{A}} dolor sit amet", "lorem ipsum dolor sit amet")]
[InlineData("{{B}} jumps over the lazy dog", "the quick brown fox jumps over the lazy dog")]
[InlineData("{{D}} at all\ntimes.", "The missile\nknows where\nit is at all\ntimes.\n")]
[InlineData("", "")]
[InlineData("ABCDEFG", "ABCDEFG")]
[InlineData("Hey guys\ndid you know\nvaporeon", "Hey guys\ndid you know\nvaporeon")]
public void ItShould_MapParagraph(string paragraphText, string expecctedText)
{
Dictionary<string, object> data = new()
{
{ "{{A}}", "lorem ipsum" },
{ "{{B}}", "the quick brown fox" },
{ "{{C}}", "het fikse aquaduct" }
{ "{{C}}", "het fikse aquaduct" },
{ "{{D}}", "The missile\nknows where\nit is" },
};

CT_P ctParagraph = new();
Expand Down

0 comments on commit 3d415eb

Please sign in to comment.