Index: third_party/WebKit/LayoutTests/typedcssom/computedstyle/custom-properties.html |
diff --git a/third_party/WebKit/LayoutTests/typedcssom/computedstyle/custom-properties.html b/third_party/WebKit/LayoutTests/typedcssom/computedstyle/custom-properties.html |
index a423ca47d4f047694bc02da04c1143e332f77efa..11bf78bc885635dd9a9775aaba90917711308bae 100644 |
--- a/third_party/WebKit/LayoutTests/typedcssom/computedstyle/custom-properties.html |
+++ b/third_party/WebKit/LayoutTests/typedcssom/computedstyle/custom-properties.html |
@@ -108,6 +108,24 @@ function t2Callback() { |
t2.done(); |
} |
+var t3 = async_test('Getting a relative URL image type registered property returns a CSSURLImageValue'); |
+function t3Callback() { |
+ t3.step(function() { |
+ testElement.style = '--my-image: url(\"resources/1x1-green.png\");'; |
+ assert_true(computedStyleMap.has('--my-image')); |
+ var result = computedStyleMap.get('--my-image'); |
+ assert_true(result instanceof CSSURLImageValue); |
+ assert_equals(result.cssText, 'url(\"' + imagePath + '\")'); |
+ // FIXME: This section of this test fails. It seems to be a bug in custom properties. See |
+ // crbug.com/719838 |
+ assert_equals(result.state, 'loaded'); |
+ assert_equals(result.intrinsicWidth, 1); |
+ assert_equals(result.intrinsicHeight, 1); |
+ assert_equals(result.intrinsicRatio, 1); |
+ }); |
+ t3.done(); |
+} |
+ |
test(function() { |
assert_true(childComputedStyleMap.has('--my-inherited-length')); |
var result = childComputedStyleMap.get('--my-inherited-length'); |
@@ -154,6 +172,7 @@ document.onreadystatechange = function() { |
if(document.readyState == 'complete') { |
t1Callback(); |
t2Callback(); |
+ t3Callback(); |
} |
}; |