mirror of
https://github.com/servo/servo.git
synced 2025-08-05 05:30:08 +01:00
Update web-platform-tests to revision cd44958a002b1ad494168e0290554644de84526e
This commit is contained in:
parent
2ed23ce4c9
commit
4443426308
103 changed files with 1740 additions and 1138 deletions
|
@ -10,14 +10,12 @@ function test_valid_value(property, value, serializedValue) {
|
|||
var stringifiedValue = JSON.stringify(value);
|
||||
|
||||
test(function(){
|
||||
var div = document.createElement('div');
|
||||
div.style[property] = value;
|
||||
assert_not_equals(div.style.getPropertyValue(property), "", "property should be set");
|
||||
|
||||
var div = document.createElement('div');
|
||||
var div = document.getElementById('target') || document.createElement('div');
|
||||
div.style[property] = "";
|
||||
div.style[property] = value;
|
||||
var readValue = div.style.getPropertyValue(property);
|
||||
if (serializedValue instanceof Array)
|
||||
assert_not_equals(readValue, "", "property should be set");
|
||||
if (Array.isArray(serializedValue))
|
||||
assert_in_array(readValue, serializedValue, "serialization should be sound");
|
||||
else
|
||||
assert_equals(readValue, serializedValue, "serialization should be canonical");
|
||||
|
@ -32,7 +30,8 @@ function test_invalid_value(property, value) {
|
|||
var stringifiedValue = JSON.stringify(value);
|
||||
|
||||
test(function(){
|
||||
var div = document.createElement('div');
|
||||
var div = document.getElementById('target') || document.createElement('div');
|
||||
div.style[property] = "";
|
||||
div.style[property] = value;
|
||||
assert_equals(div.style.getPropertyValue(property), "");
|
||||
}, "e.style['" + property + "'] = " + stringifiedValue + " should not set the property value");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue