| OLD | NEW |
| 1 <!DOCTYPE html> | 1 <!DOCTYPE html> |
| 2 <html> | 2 <html> |
| 3 <head> | 3 <head> |
| 4 <script src="../../../resources/js-test.js"></script> | 4 <script src="../../../resources/js-test.js"></script> |
| 5 <script src="../../forms/resources/picker-common.js"></script> | 5 <script src="../../forms/resources/picker-common.js"></script> |
| 6 <script src="resources/calendar-picker-common.js"></script> | 6 <script src="resources/calendar-picker-common.js"></script> |
| 7 </head> | 7 </head> |
| 8 <body> | 8 <body> |
| 9 <p id="description"></p> | 9 <p id="description"></p> |
| 10 <div id="console"></div> | 10 <div id="console"></div> |
| 11 <input type=month id=month value="2000-01"> | 11 <input type=month id=month value="2000-01"> |
| 12 <script> | 12 <script> |
| 13 description("Tests if month picker key bindings work as expected."); | 13 description("Tests if month picker key bindings work as expected."); |
| 14 | 14 |
| 15 debug('Check that page popup doesn\'t exist at first.'); | 15 debug('Check that page popup doesn\'t exist at first.'); |
| 16 shouldBeNull('document.getElementById("mock-page-popup")'); | 16 shouldBeNull('document.getElementById("mock-page-popup")'); |
| 17 | 17 |
| 18 openPickerWithMock(document.getElementById('month'), test1); | 18 openPicker(document.getElementById('month'), test1); |
| 19 | 19 |
| 20 function test1() { | 20 function test1() { |
| 21 debug('Check that page popup exists.'); | 21 debug('Check that page popup exists.'); |
| 22 shouldBeEqualToString('popupWindow.pagePopupController.toString()', '[object
PagePopupController]'); | 22 shouldBeEqualToString('popupWindow.pagePopupController.toString()', '[object
PagePopupController]'); |
| 23 | 23 |
| 24 shouldBeFalse('isCalendarTableScrollingWithAnimation()'); | 24 shouldBeFalse('isCalendarTableScrollingWithAnimation()'); |
| 25 shouldBeEqualToString('currentMonth()', '2000-01'); | 25 shouldBeEqualToString('currentMonth()', '2000-01'); |
| 26 shouldBeEqualToString('selectedValue()', '2000-01'); | 26 shouldBeEqualToString('selectedValue()', '2000-01'); |
| 27 shouldBeEqualToString('selectedDayCells()', '2000-01-01,2000-01-02,2000-01-0
3,2000-01-04,2000-01-05,2000-01-06,2000-01-07,2000-01-08,2000-01-09,2000-01-10,2
000-01-11,2000-01-12,2000-01-13,2000-01-14,2000-01-15,2000-01-16,2000-01-17,2000
-01-18,2000-01-19,2000-01-20,2000-01-21,2000-01-22,2000-01-23,2000-01-24,2000-01
-25,2000-01-26,2000-01-27,2000-01-28,2000-01-29,2000-01-30,2000-01-31'); | 27 shouldBeEqualToString('selectedDayCells()', '2000-01-01,2000-01-02,2000-01-0
3,2000-01-04,2000-01-05,2000-01-06,2000-01-07,2000-01-08,2000-01-09,2000-01-10,2
000-01-11,2000-01-12,2000-01-13,2000-01-14,2000-01-15,2000-01-16,2000-01-17,2000
-01-18,2000-01-19,2000-01-20,2000-01-21,2000-01-22,2000-01-23,2000-01-24,2000-01
-25,2000-01-26,2000-01-27,2000-01-28,2000-01-29,2000-01-30,2000-01-31'); |
| 28 shouldBeEqualToString('highlightedValue()', '2000-01'); | 28 shouldBeEqualToString('highlightedValue()', '2000-01'); |
| (...skipping 223 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 252 return null; | 252 return null; |
| 253 var identifier = "." + element.className; | 253 var identifier = "." + element.className; |
| 254 if (element.value) | 254 if (element.value) |
| 255 identifier += "[value=" + element.value + "]"; | 255 identifier += "[value=" + element.value + "]"; |
| 256 return identifier; | 256 return identifier; |
| 257 } | 257 } |
| 258 | 258 |
| 259 </script> | 259 </script> |
| 260 </body> | 260 </body> |
| 261 </html> | 261 </html> |
| OLD | NEW |