aboutsummaryrefslogtreecommitdiff
path: root/src/test/java/org/zwobble
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/java/org/zwobble')
-rw-r--r--src/test/java/org/zwobble/mammoth/tests/MammothTests.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/test/java/org/zwobble/mammoth/tests/MammothTests.java b/src/test/java/org/zwobble/mammoth/tests/MammothTests.java
index e280d11..2fd6ba0 100644
--- a/src/test/java/org/zwobble/mammoth/tests/MammothTests.java
+++ b/src/test/java/org/zwobble/mammoth/tests/MammothTests.java
@@ -26,6 +26,13 @@ public class MammothTests {
deepEquals(success("<p>Walking on imported air</p>")));
}
+ @Test
+ public void canReadFilesWithUtf8Bom() {
+ assertThat(
+ convertToHtml("utf8-bom.docx"),
+ deepEquals(success("<p>This XML has a byte order mark.</p>")));
+ }
+
private Result<String> convertToHtml(String name) {
File file = TestData.file(name);
return Mammoth.convertToHtml(file);