Skip to content

Commit 7b7030d

Browse files
committed
Update CSSStyleProperties.test.js
Unit test for jsdom/jsdom#3940
1 parent 72a43fa commit 7b7030d

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

test/CSSStyleProperties.test.js

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1519,4 +1519,12 @@ describe("regression test for https://github.com/jsdom/cssstyle/issues/214", ()
15191519
assert.strictEqual(style.borderWidth, "0.2rem");
15201520
assert.strictEqual(style.border, "");
15211521
});
1522+
1523+
it("should get value and priority", () => {
1524+
const style = new CSSStyleProperties();
1525+
style.cssText = "word-spacing: 1px !important;";
1526+
assert.strictEqual(style.cssText, "word-spacing: 1px !important;", "cssText");
1527+
assert.strictEqual(style.getPropertyValue("word-spacing"), "1px", "value");
1528+
assert.strictEqual(style.getPropertyPriority("word-spacing"), "important", "priority");
1529+
});
15221530
});

0 commit comments

Comments
 (0)