From 6bef85a8fde03b50de4aa78064ab4c32ad54041c Mon Sep 17 00:00:00 2001 From: Michael Williamson Date: Sat, 19 Nov 2016 12:03:32 +0000 Subject: Introduce matcher for style name --- test/document-to-html.tests.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'test/document-to-html.tests.js') diff --git a/test/document-to-html.tests.js b/test/document-to-html.tests.js index b7a0251..2543779 100644 --- a/test/document-to-html.tests.js +++ b/test/document-to-html.tests.js @@ -69,7 +69,7 @@ test('uses style mappings to pick HTML element for docx paragraph', function() { var converter = new DocumentConverter({ styleMap: [ { - from: documentMatchers.paragraph({styleName: "Heading 1"}), + from: documentMatchers.paragraph({styleName: documentMatchers.equalTo("Heading 1")}), to: htmlPaths.topLevelElement("h1") } ] @@ -86,7 +86,7 @@ test('mappings for style names are case insensitive', function() { var converter = new DocumentConverter({ styleMap: [ { - from: documentMatchers.paragraph({styleName: "Heading 1"}), + from: documentMatchers.paragraph({styleName: documentMatchers.equalTo("Heading 1")}), to: htmlPaths.topLevelElement("h1") } ] @@ -301,7 +301,7 @@ test('run styles are converted to HTML if mapping exists', function() { var converter = new DocumentConverter({ styleMap: [ { - from: documentMatchers.run({styleName: "Heading 1 Char"}), + from: documentMatchers.run({styleName: documentMatchers.equalTo("Heading 1 Char")}), to: htmlPaths.elements(["strong"]) } ] -- cgit v1.2.3