diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/document-to-html.tests.js | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/document-to-html.tests.js b/tests/document-to-html.tests.js index a53039b..7c84482 100644 --- a/tests/document-to-html.tests.js +++ b/tests/document-to-html.tests.js @@ -131,6 +131,17 @@ describe('DocumentConverter', function() { assert.equal(result.html, "<strong>Hello.</strong>"); }); }); + + test('docx hyperlink is converted to <a>', function() { + var hyperlink = new documents.Hyperlink( + [runOfText("Hello.")], + {href: "http://www.example.com"} + ); + var converter = new DocumentConverter(); + return converter.convertToHtml(hyperlink).then(function(result) { + assert.equal(result.html, '<a href="http://www.example.com">Hello.</a>'); + }); + }); }); function paragraphOfText(text, styleName) { |
