4 <script src=
"../../../resources/js-test.js"></script>
5 <script src=
"../../forms/resources/picker-common.js"></script>
6 <script src=
"resources/calendar-picker-common.js"></script>
9 <p id=
"description"></p>
10 <div id=
"console"></div>
11 <input type=datetime-local id=datetimelocal
value=
"2011-12-31T12:53:45">
13 description("Tests if calendar picker works for datetime-local as expected.");
15 debug('Check that page popup doesn\'t exist at first.');
16 shouldBeNull('document.getElementById("mock-page-popup")');
18 openPicker(document
.getElementById('datetimelocal'), test
);
21 shouldBeEqualToString('selectedValue()', '2011-12-31');
22 shouldBeEqualToString('highlightedValue()', '2011-12-31');
24 eventSender
.keyDown('rightArrow');
25 shouldBeEqualToString('highlightedValue()', '2012-01-01');
28 eventSender
.keyDown('\n');
29 shouldBeEqualToString('document.getElementById("datetimelocal").value', '2012-01-01T12:53:45');