From 72ab36671522ceddcbfc3ab753d25d905815603a Mon Sep 17 00:00:00 2001 From: Michael Williamson Date: Sun, 16 Aug 2015 14:07:52 +0100 Subject: Test that embedded style map is written to separate file --- tests/docx/style-map.tests.js | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/tests/docx/style-map.tests.js b/tests/docx/style-map.tests.js index a14ffb3..d120289 100644 --- a/tests/docx/style-map.tests.js +++ b/tests/docx/style-map.tests.js @@ -16,6 +16,16 @@ describe("zipfile", function() { assert.equal(contents, "p => h1"); }); }); + + test('embedded style map is written to separate file', function() { + var zip = emptyZipFile(); + + styleMap.writeStyleMap(zip, "p => h1"); + + return zip.read("mammoth/style-map", "utf8").then(function(contents) { + assert.equal(contents, "p => h1"); + }); + }); }); function emptyZipFile() { -- cgit v1.2.3