Index: LayoutTests/scrollingcoordinator/non-fast-scrollable-region-transformed-iframe.html |
diff --git a/LayoutTests/scrollingcoordinator/non-fast-scrollable-region-transformed-iframe.html b/LayoutTests/scrollingcoordinator/non-fast-scrollable-region-transformed-iframe.html |
index 6c44498651611f4e1b688dca3eab5466480227cb..8b517ba6e547ac5d4ac6ca9f8d3b6b3c6bd6bd34 100644 |
--- a/LayoutTests/scrollingcoordinator/non-fast-scrollable-region-transformed-iframe.html |
+++ b/LayoutTests/scrollingcoordinator/non-fast-scrollable-region-transformed-iframe.html |
@@ -1,10 +1,36 @@ |
<!DOCTYPE html> |
-<html> |
-<head> |
+<style> |
+ iframe { |
+ position: absolute; |
+ left: 200px; |
+ top: 200px; |
+ height: 120px; |
+ width: 120px; |
+ padding: 10px; |
+ border: none; |
+ transform:scale(2); |
Rick Byers
2015/01/26 22:28:32
nit: missing space
majidvp
2015/01/26 22:42:50
Done.
|
+ } |
+</style> |
+ |
+<iframe src="data:text/html;charset=utf-8,<html><body style='width:1000px; height:1000px;'><p style='font-size: 6px'>Should be covered by a green overlay.</p></body></html>"></iframe> |
+<div id="console"></div> |
+ |
+<script src="../resources/js-test.js"></script> |
<script src="resources/non-fast-scrollable-region-testing.js"></script> |
-</head> |
-<body onload="runNonFastScrollableRegionTest();"> |
-<iframe src="data:text/html;charset=utf-8,<html><body style='width:1000px;height:1000px;'></body></html>" style="position:absolute;left:200px;top:150px;width;150px;height:200px;transform:scale(2);padding:10px;"></iframe> |
-</body> |
-</html> |
+<script> |
+ window.jsTestIsAsync = true; |
+ description('This test ensures non-fast scrollable areas are calculated ' + |
+ 'correctly when page is scaled.'); |
Rick Byers
2015/01/26 22:28:32
this description is stale - this is about a scaled
majidvp
2015/01/26 22:42:50
Done.
|
+ |
+ onload = function() { |
+ awaitCompsitingUpdate(function(){ |
+ nonFastScrollableRects = window.internals.nonFastScrollableRects(document); |
+ shouldBe('nonFastScrollableRects.length', '1'); |
+ shouldBeEqualToString('rectToString(nonFastScrollableRects[0])', '[150, 150, 240, 240]'); |
+ |
+ drawNonFastScrollableRegionOverlays(); |
+ finishJSTest(); |
+ }); |
+ }; |
+</script> |