| OLD | NEW |
| (Empty) |
| 1 <!DOCTYPE html> | |
| 2 <html> | |
| 3 <body> | |
| 4 <script src="../../../../../fast/js/resources/js-test-pre.js"></script> | |
| 5 <p id="description"></p> | |
| 6 <div id="console"></div> | |
| 7 <input type="date" id="date1" value="2000-01-02"> | |
| 8 <script> | |
| 9 description("Tests if calendar picker key bindings work as expected."); | |
| 10 if (window.internals) | |
| 11 internals.setEnableMockPagePopup(true); | |
| 12 var date1 = document.getElementById('date1'); | |
| 13 date1.offsetTop; // date1 needs to have non-empty bound rectangle. | |
| 14 debug('Check that page popup doesn\'t exist at first.'); | |
| 15 shouldBeNull('document.getElementById("mock-page-popup")'); | |
| 16 | |
| 17 var event = document.createEvent('KeyboardEvent'); | |
| 18 event.initKeyboardEvent('keydown', true, true, document.defaultView, 'F4'); | |
| 19 date1.dispatchEvent(event); | |
| 20 shouldBeNonNull('document.getElementById("mock-page-popup")'); | |
| 21 </script> | |
| 22 <script src="../../../../../fast/js/resources/js-test-post.js"></script> | |
| 23 </body> | |
| 24 </html> | |
| OLD | NEW |