diff options
| author | jaceyshome <jaceyshome@gmail.com> | 2015-05-21 21:14:15 +1000 |
|---|---|---|
| committer | jaceyshome <jaceyshome@gmail.com> | 2015-05-21 21:14:15 +1000 |
| commit | c608d035569e16c81ea29ecf2a904e227379cecd (patch) | |
| tree | e969ba13a64710c29fc9167d5950619e0b9dacc4 /tests | |
| parent | 969d80c62e7d5d5ed41a3dc7ec8f5f8bdec59a91 (diff) | |
styles names should be null by default
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/docx/styles-reader.tests.js | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/docx/styles-reader.tests.js b/tests/docx/styles-reader.tests.js index 7899b1b..f76dfc2 100644 --- a/tests/docx/styles-reader.tests.js +++ b/tests/docx/styles-reader.tests.js @@ -59,6 +59,17 @@ describe('readStylesXml', function() { }); assert.equal(styles.findParagraphStyleById("Heading1").name, "Heading 1"); }); + + test('styles names should be null by default', function() { + var styles = readStylesXml({ + root: new XmlElement("w:styles", {}, [ + paragraphStyleElement("Heading1", null), + characterStyleElement("Heading1Char", null) + ]) + }); + assert.equal(styles.findParagraphStyleById("Heading1Char"), null); + assert.equal(styles.findCharacterStyleById("Heading1"), null); + }); }); function paragraphStyleElement(id, name) { |
