mirror of
https://github.com/servo/servo.git
synced 2025-08-31 01:58:23 +01:00
Update web-platform-tests to revision 2b7dace05fc1869398ee24f84fda4c0e4c0455ae
This commit is contained in:
parent
b23125d590
commit
6c901de216
844 changed files with 19802 additions and 3093 deletions
|
@ -1,6 +1,5 @@
|
|||
<!DOCTYPE html>
|
||||
<title>NoModificationAllowedError when mutating read only properties</title>
|
||||
<link rel="author" title="Anders Hartvoll Ruud" href="andruud@chromium.org">
|
||||
<link rel="help" href="https://www.w3.org/TR/cssom-1/#dom-cssstyledeclaration-setpropertyvalue">
|
||||
<meta name="assert" content="This test verifies that NoModificationAllowedError is thrown when mutating read only properties" />
|
||||
<script src="/resources/testharness.js"></script>
|
||||
|
|
|
@ -58,6 +58,20 @@
|
|||
assert_equals(testElem.style.margin, "20px");
|
||||
assert_equals(testElem.style.cssText, "margin: 20px;")
|
||||
}, "Shorthand serialization after setting");
|
||||
|
||||
test(function() {
|
||||
const testElem = document.getElementById("test");
|
||||
testElem.style.cssText = "margin: initial;";
|
||||
assert_equals(testElem.style.margin, "initial");
|
||||
assert_equals(testElem.style.cssText, "margin: initial;");
|
||||
}, "Shorthand serialization with 'initial' value.");
|
||||
|
||||
test(function() {
|
||||
const testElem = document.getElementById("test");
|
||||
testElem.style.setProperty("margin-top", "initial", "important");
|
||||
assert_equals(testElem.style.margin, "");
|
||||
assert_equals(testElem.style.cssText, "margin-top: initial !important; margin-right: initial; margin-bottom: initial; margin-left: initial;");
|
||||
}, "Shorthand serialization with 'initial' value, one longhand with important flag.");
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue