aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorMichael Williamson <mike@zwobble.org>2020-09-09 10:31:45 +0100
committerGitHub <noreply@github.com>2020-09-09 10:31:45 +0100
commit542503a1f911109184be1fcb0a4902b9201ea54b (patch)
tree051d4ebd396efd7d05245677c4319a2c6955e8ca /test
parent1746e4a8ed68f17e413f156e7f5ee76303806ccc (diff)
parent091111ce4b0bece922d814a63e8f294cf52b79a6 (diff)
Merge pull request #250 from adobe-rnd/fix-underline-none
Fix: Underline with value 'none' is wrongly detected
Diffstat (limited to 'test')
-rw-r--r--test/docx/body-reader.tests.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/docx/body-reader.tests.js b/test/docx/body-reader.tests.js
index 48f6b16..50506ae 100644
--- a/test/docx/body-reader.tests.js
+++ b/test/docx/body-reader.tests.js
@@ -459,6 +459,13 @@ test("isUnderline is true if underline element is present", function() {
assert.equal(run.isUnderline, true);
});
+test("isUnderline is false if underline element is 'none'", function() {
+ var underlineXml = new XmlElement("w:u", {"w:val": "none"});
+ var runXml = runWithProperties([underlineXml]);
+ var run = readXmlElementValue(runXml);
+ assert.equal(run.isUnderline, false);
+});
+
test("isStrikethrough is false if strikethrough element is not present", function() {
var runXml = runWithProperties([]);
var run = readXmlElementValue(runXml);