n_wang@apple.com | 481a02f | 2018-03-23 01:41:44 +0000 | [diff] [blame] | 1 | <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> |
| 2 | <html> |
| 3 | <head> |
| 4 | <script src="../resources/js-test-pre.js"></script> |
| 5 | </head> |
| 6 | <body id="body"> |
| 7 | |
| 8 | <table id="table"> |
| 9 | <thead> |
| 10 | <tr role="row"><th>Item 1</th></tr> |
| 11 | </thead> |
| 12 | <tbody></tbody> |
| 13 | </table> |
| 14 | |
| 15 | <p id="description"></p> |
| 16 | <div id="console"></div> |
| 17 | |
| 18 | <script> |
| 19 | |
| 20 | description("This tests if a native tr element uses the 'row' role, but forgets to add role='grid' to the native table element, the table still exposes the right numbers of rows/cells."); |
| 21 | |
| 22 | if (window.accessibilityController) { |
| 23 | var table = accessibilityController.accessibleElementById("table"); |
| 24 | shouldBe("table.rowCount", "1"); |
| 25 | shouldBe("table.columnCount", "1"); |
| 26 | } |
| 27 | |
| 28 | </script> |
| 29 | |
| 30 | <script src="../resources/js-test-post.js"></script> |
| 31 | </body> |
| 32 | </html> |