diff options
| author | Michael Williamson <mike@zwobble.org> | 2013-11-26 13:54:44 +0000 |
|---|---|---|
| committer | Michael Williamson <mike@zwobble.org> | 2013-11-26 13:54:44 +0000 |
| commit | 019785ec43c367c2f5c7c90f445bc9e1fa6d61a5 (patch) | |
| tree | f3359e2a2bb39a35c48180a1ed6d2a7a0d35e557 /tests/document-xml-reader.tests.js | |
| parent | aeb60aaf362200477e36c3c5ae17f8c063a21568 (diff) | |
Handle hyperlink elements without relationship ID
Diffstat (limited to 'tests/document-xml-reader.tests.js')
| -rw-r--r-- | tests/document-xml-reader.tests.js | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/document-xml-reader.tests.js b/tests/document-xml-reader.tests.js index 01ecac4..d2bcc76 100644 --- a/tests/document-xml-reader.tests.js +++ b/tests/document-xml-reader.tests.js @@ -233,6 +233,13 @@ describe("readXmlElement: ", function() { assert.deepEqual(result.value.href, "http://example.com"); assert.deepEqual(result.value.children[0].type, "run"); }); + + test("w:hyperlink is ignored if it does not have a relationship ID", function() { + var runXml = new XmlElement("w:r", {}, []); + var hyperlinkXml = new XmlElement("w:hyperlink", {}, [runXml]); + var result = readXmlElement(hyperlinkXml); + assert.deepEqual(result.value[0].type, "run"); + }); }); function runWithProperties(children) { |
