Index: third_party/WebKit/LayoutTests/svg/as-list-image/svg-list-image-intrinsic-size-zoom.html |
diff --git a/third_party/WebKit/LayoutTests/svg/as-list-image/svg-list-image-intrinsic-size-zoom.html b/third_party/WebKit/LayoutTests/svg/as-list-image/svg-list-image-intrinsic-size-zoom.html |
index 7e9f7f52702de7ef3cfa93015e75031167bd550b..a449ff406ea173c9b981b498ad18db37f4ff61a5 100644 |
--- a/third_party/WebKit/LayoutTests/svg/as-list-image/svg-list-image-intrinsic-size-zoom.html |
+++ b/third_party/WebKit/LayoutTests/svg/as-list-image/svg-list-image-intrinsic-size-zoom.html |
@@ -1,24 +1,29 @@ |
<!DOCTYPE html> |
-<title>Zoomed SVG in list-style-image</title> |
+<title>Zoomed SVG and raster image in list-style-image</title> |
<script src="../../resources/testharness.js"></script> |
<script src="../../resources/testharnessreport.js"></script> |
<style> |
- ul { font-family: Ahem; } |
- ul li { |
- list-style-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1 1'><rect width='1' height='1' fill='green'/></svg>"); |
- font-size: 30px; |
- color: green; |
- list-style-position: inside; |
- line-height: 1em; |
- } |
+ul { font-family: Ahem; } |
+ul li { |
+ font-size: 30px; |
+ color: green; |
+ list-style-position: inside; |
+ line-height: 1em; |
+} |
+ul li.svg { |
+ list-style-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1 1'><rect width='1' height='1' fill='green'/></svg>"); |
+} |
+ul li.png { |
+ list-style-image: url("resources/green15x15.png"); |
+} |
</style> |
-<ul><li></ul> |
+<ul><li class="svg"><li class="png"></ul> |
<script> |
- var ul = document.querySelector('ul'); |
- [ 2, 3, 4, 5, 1].forEach(function(zoom) { |
- test(function() { |
- document.body.style.zoom = zoom; |
- assert_approx_equals(ul.getBoundingClientRect().height, 30, 0.5); |
- }, 'Zoom to ' + zoom + " and list height should be equal to line-height"); |
- }); |
+var ul = document.querySelector('ul'); |
+[ 2, 3, 4, 5, 0.5, 0.2, 1].forEach(function(zoom) { |
+ test(function() { |
+ document.body.style.zoom = zoom; |
+ assert_approx_equals(ul.getBoundingClientRect().height, 60, 0.5); |
+ }, 'Zoom to ' + zoom + " and list height should be equal to line-height"); |
+}); |
</script> |