blob: 95bbb41dc769e9f62296df27292096dea8125db1 [file] [log] [blame]
This test zooms and scrolls the page and checks that the layout and visual viewports respond as expected.
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
JSON.stringify(internals.layoutViewportRect()) is {"x":0,"y":0,"width":785,"height":585,"top":0,"right":785,"bottom":585,"left":0}
JSON.stringify(internals.visualViewportRect()) is {"x":0,"y":0,"width":392.5,"height":292.5,"top":0,"right":392.5,"bottom":292.5,"left":0}
Scrolled to -475, 525
JSON.stringify(internals.layoutViewportRect()) is {"x":-475,"y":232.5,"width":785,"height":585,"top":232.5,"right":310,"bottom":817.5,"left":-475}
JSON.stringify(internals.visualViewportRect()) is {"x":-475,"y":525,"width":392.5,"height":292.5,"top":525,"right":-82.5,"bottom":817.5,"left":-475}
Scrolled to -100, 776
JSON.stringify(internals.layoutViewportRect()) is {"x":-475,"y":483.5,"width":785,"height":585,"top":483.5,"right":310,"bottom":1068.5,"left":-475}
JSON.stringify(internals.visualViewportRect()) is {"x":-100,"y":776,"width":392.5,"height":292.5,"top":776,"right":292.5,"bottom":1068.5,"left":-100}
Scrolled to -50, 300
JSON.stringify(internals.layoutViewportRect()) is {"x":-442.5,"y":300,"width":785,"height":585,"top":300,"right":342.5,"bottom":885,"left":-442.5}
JSON.stringify(internals.visualViewportRect()) is {"x":-50,"y":300,"width":392.5,"height":292.5,"top":300,"right":342.5,"bottom":592.5,"left":-50}
PASS successfullyParsed is true
TEST COMPLETE