From 955a29e828d40123ec64a479b1c4c5164db3c681 Mon Sep 17 00:00:00 2001 From: Michael Williamson Date: Mon, 29 Aug 2016 11:37:27 +0100 Subject: Wire up comment conversion code --- src/test/java/org/zwobble/mammoth/tests/MammothTests.java | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'src/test/java/org/zwobble/mammoth/tests/MammothTests.java') diff --git a/src/test/java/org/zwobble/mammoth/tests/MammothTests.java b/src/test/java/org/zwobble/mammoth/tests/MammothTests.java index 455fa0c..fff4cb3 100644 --- a/src/test/java/org/zwobble/mammoth/tests/MammothTests.java +++ b/src/test/java/org/zwobble/mammoth/tests/MammothTests.java @@ -154,6 +154,19 @@ public class MammothTests { "
  • Fin. ↑

  • ")); } + @Test + public void whenStyleMappingIsDefinedForCommentReferencesThenCommentsAreIncluded() throws IOException { + assertThat( + convertToHtml("comments.docx", mammoth -> mammoth.idPrefix("doc-42-").addStyleMap("comment-reference => sup")), + isSuccess( + "

    Ouch" + + "[MW1]." + + "[MW2]

    " + + "
    Comment [MW1]

    A tachyon walks into a bar. ↑

    " + + "
    Comment [MW2]

    Fin. ↑

    " + )); + } + @Test public void relationshipsAreReadForEachFileContainingBodyXml() throws IOException { assertThat( -- cgit v1.2.3