596ba5c9dada5c81956ce1272519a65cf9163f4b
[WebKit-https.git] / LayoutTests / fast / spatial-navigation / snav-hidden-iframe-zero-size.html
1 <html>
2   <head>
3     <script src="../js/resources/js-test-pre.js"></script>
4     <script src="resources/spatial-navigation-utils.js"></script>
5     <script type="application/javascript">
6
7     var resultMap = [
8       ["Down", "end"],
9       ["DONE", "DONE"]
10     ];
11
12     if (window.testRunner) {
13       testRunner.dumpAsText();
14       testRunner.setSpatialNavigationEnabled(true);
15       testRunner.overridePreference("WebKitTabToLinksPreferenceKey", 1);
16       testRunner.waitUntilDone();
17     }
18
19     function runTest()
20     {
21       // starting the test itself: get to a known place.
22       document.getElementById("start").focus();
23
24       initTest(resultMap, testCompleted);
25     }
26
27     function testCompleted()
28     {
29       if (window.testRunner)
30         testRunner.notifyDone();
31     }
32
33     window.onload = runTest;
34
35     </script>
36     <script src="js/resources/js-test-post.js"></script>
37   </head>
38
39   <body id="some-content" xmlns="http://www.w3.org/1999/xhtml">
40       <p>This is <a id="start" href="a">link_1</a>.</p>
41        <br>This is <iframe id="1" width=0 height=0  src="data:text/html,
42         <body>
43           <a id='11' href='http://a'>b</a>
44           <a id='12' href='http://a'>c</a>
45           <a id='13' href='http://a'>d</a>
46         </body>
47         "></iframe><br> an iframe with size 0.<br>
48      <p>This is <a id="end" href="a">link_2</a>.</p>
49     <div id="console"></div>
50     <p>This test is to test that an iframe with size 0 does not get focus, and neither do its descendants.
51   </body>
52 </html>