summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Williamson <mike@zwobble.org>2015-09-12 15:53:49 +0100
committerMichael Williamson <mike@zwobble.org>2015-09-12 15:53:49 +0100
commit27c4e1390c8c28acb0b20d5a42255c0de0b33db5 (patch)
tree981aa15a027f827dc088093dbcbab32f53a4e721
parentd73dce45a781a15e18a953a3507fb3ccd740ed89 (diff)
Test that null is returned when trying to read non-existent style map
-rw-r--r--tests/docx/style-map.tests.js8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/docx/style-map.tests.js b/tests/docx/style-map.tests.js
index 0c8ef23..55171f8 100644
--- a/tests/docx/style-map.tests.js
+++ b/tests/docx/style-map.tests.js
@@ -7,6 +7,14 @@ var styleMap = require("../../lib/docx/style-map");
var test = require("../testing").test;
describe("style-map", function() {
+ test('reading embedded style map on document without embedded style map returns null', function() {
+ var zip = normalDocx();
+
+ return styleMap.readStyleMap(zip).then(function(contents) {
+ assert.equal(contents, null);
+ });
+ });
+
test('embedded style map can be read after being written', function() {
var zip = normalDocx();