blob: f22675af84e05bb30206d60ce5c5ef6616b4eede [file] [log] [blame]
n_wang@apple.comf7358832018-05-10 02:07:34 +00001This tests that scrolling to make an element visible works properly when there's an iframe off screen.
2
3On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
4
5
65000-pixel box
7
8
9Test scrolling an offscreen iframe.
10PASS window.pageYOffset is 0
11
12Scroll lower target to visible.
13The iframe should be scrolled into view
14PASS scrolledYOffset > 0 is true
15Test the lower target should be scrolled into view.
16PASS scrolledIntoView is true
17
18Scroll upper target to visible.
19The main window shouldn't scroll.
20PASS window.pageYOffset == scrolledYOffset is true
21Test the upper target should be scrolled into view.
22PASS scrolledIntoView is true
23
24Reset scrolling. Test scrolling in nested iframes.
25PASS window.pageYOffset is 0
26
27Scroll inner button to visible.
28Test the button inside the inner frame should be scrolled into view
29PASS scrolledIntoView is true
30The inner iframe should be scrolled into view
31PASS outterFrameWindow.pageYOffset > 0 is true
32
33Scroll outter text element to visible.
34The Y offset of the outter iframe should be reset.
35PASS outterFrameWindow.pageYOffset is 0
36PASS successfullyParsed is true
37
38TEST COMPLETE
39