Bug 1497153 [wpt PR 13416] - [css-properties-values-api] Include initial values in computedStyleMap., a=testonly
authorAnders Hartvoll Ruud <andruud@chromium.org>
Thu, 11 Oct 2018 10:03:54 +0000
changeset 496802 696aabb8f7015b1441e0fc03ed3ab8a7aff66216
parent 496801 3d1e70d63f789715ac2be51029d613c8581d186d
child 496803 40e4e38aceb9741999de7b9728339fa47eef82f2
push id9984
push userffxbld-merge
push dateMon, 15 Oct 2018 21:07:35 +0000
treeherdermozilla-beta@183d27ea8570 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstestonly
bugs1497153, 13416, 641877, 1264575, 598243
milestone64.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1497153 [wpt PR 13416] - [css-properties-values-api] Include initial values in computedStyleMap., a=testonly Automatic update from web-platform-tests[css-properties-values-api] Include initial values in computedStyleMap. Registered properties with initial values are currently missing from the computedStyleMap, because such properties are not explicitly stored on individual computed styles. To fix this, do an extra pass over the PropertyRegistrations to "fill in blanks" with initial values. R=chrishtr@chromium.org Bug: 641877 Change-Id: If36cb3ef3d419ff547e8b4073cdd9ec298c539a0 Reviewed-on: https://chromium-review.googlesource.com/c/1264575 Reviewed-by: Chris Harrelson <chrishtr@chromium.org> Commit-Queue: Anders Ruud <andruud@chromium.org> Cr-Commit-Position: refs/heads/master@{#598243} -- wpt-commits: 813f11ba0825d8af712f6707d6cf34aaf5e30b82 wpt-pr: 13416
testing/web-platform/tests/css/css-properties-values-api/typedom.tentative.html
--- a/testing/web-platform/tests/css/css-properties-values-api/typedom.tentative.html
+++ b/testing/web-platform/tests/css/css-properties-values-api/typedom.tentative.html
@@ -589,9 +589,17 @@ test(function(){
         // the properties have compatible syntaxes.
         assert_throws(new TypeError(), () => {
             target.attributeStyleMap.clear();
             target.attributeStyleMap.set(prop1, value);
         });
     }
 }, 'Direct CSSStyleValue instances are tied to their associated property');
 
+// StylePropertyMapReadOnly iteration
+
+test(function(){
+    let name = gen_prop('<length>', '10px');
+    let result = Array.from(target.computedStyleMap()).filter(e => e[0] == name)[0];
+    assert_true(typeof(result) !== 'undefined');
+}, 'Registered property with initial value show up on iteration of computedStyleMap');
+
 </script>