Skip to content

Commit adb3327

Browse files
committed
Update 2012.js
1 parent db64218 commit adb3327

File tree

1 file changed

+32
-32
lines changed
  • tests/suites/keyboard_navigation

1 file changed

+32
-32
lines changed

tests/suites/keyboard_navigation/2012.js

Lines changed: 32 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ test('by day (right/left arrows)', function(){
2525
var target;
2626

2727
equal(this.dp.viewMode, 0);
28-
target = this.picker.find('.datepicker-days thead th.switch');
28+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
2929
equal(target.text(), 'March 2012', 'Title is "March 2012"');
3030

3131
// Navigation: -1 day, left arrow key
@@ -37,7 +37,7 @@ test('by day (right/left arrows)', function(){
3737
datesEqual(this.dp.viewDate, UTCDate(2012, 2, 30));
3838
datesEqual(this.dp.date, UTCDate(2012, 2, 30));
3939
// Month not changed
40-
target = this.picker.find('.datepicker-days thead th.switch');
40+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
4141
equal(target.text(), 'March 2012', 'Title is "March 2012"');
4242

4343
// Navigation: +1 day, right arrow key
@@ -49,15 +49,15 @@ test('by day (right/left arrows)', function(){
4949
datesEqual(this.dp.viewDate, UTCDate(2012, 3, 1));
5050
datesEqual(this.dp.date, UTCDate(2012, 3, 1));
5151
// Month changed: April 1 (this is not a joke!)
52-
target = this.picker.find('.datepicker-days thead th.switch');
52+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
5353
equal(target.text(), 'April 2012', 'Title is "April 2012"');
5454
});
5555

5656
test('by week (up/down arrows)', function(){
5757
var target;
5858

5959
equal(this.dp.viewMode, 0);
60-
target = this.picker.find('.datepicker-days thead th.switch');
60+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
6161
equal(target.text(), 'March 2012', 'Title is "March 2012"');
6262

6363
// Navigation: -1 week, up arrow key
@@ -69,7 +69,7 @@ test('by week (up/down arrows)', function(){
6969
datesEqual(this.dp.viewDate, UTCDate(2012, 2, 24));
7070
datesEqual(this.dp.date, UTCDate(2012, 2, 24));
7171
// Month not changed
72-
target = this.picker.find('.datepicker-days thead th.switch');
72+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
7373
equal(target.text(), 'March 2012', 'Title is "March 2012"');
7474

7575
// Navigation: +1 week, down arrow key
@@ -80,15 +80,15 @@ test('by week (up/down arrows)', function(){
8080
});
8181
datesEqual(this.dp.viewDate, UTCDate(2012, 3, 7));
8282
datesEqual(this.dp.date, UTCDate(2012, 3, 7));
83-
target = this.picker.find('.datepicker-days thead th.switch');
83+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
8484
equal(target.text(), 'April 2012', 'Title is "April 2012"');
8585
});
8686

8787
test('by month, v1 (shift + left/right arrows)', function(){
8888
var target;
8989

9090
equal(this.dp.viewMode, 0);
91-
target = this.picker.find('.datepicker-days thead th.switch');
91+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
9292
equal(target.text(), 'March 2012', 'Title is "March 2012"');
9393

9494
// Navigation: -1 month, shift + left arrow key
@@ -101,7 +101,7 @@ test('by month, v1 (shift + left/right arrows)', function(){
101101
datesEqual(this.dp.viewDate, UTCDate(2012, 1, 29));
102102
datesEqual(this.dp.date, UTCDate(2012, 1, 29));
103103
// Month not changed
104-
target = this.picker.find('.datepicker-days thead th.switch');
104+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
105105
equal(target.text(), 'February 2012', 'Title is "February 2012"');
106106

107107
// Navigation: +1 month, shift + right arrow key
@@ -113,15 +113,15 @@ test('by month, v1 (shift + left/right arrows)', function(){
113113
});
114114
datesEqual(this.dp.viewDate, UTCDate(2012, 3, 29));
115115
datesEqual(this.dp.date, UTCDate(2012, 3, 29));
116-
target = this.picker.find('.datepicker-days thead th.switch');
116+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
117117
equal(target.text(), 'April 2012', 'Title is "April 2012"');
118118
});
119119

120120
test('by month, v2 (shift + up/down arrows)', function(){
121121
var target;
122122

123123
equal(this.dp.viewMode, 0);
124-
target = this.picker.find('.datepicker-days thead th.switch');
124+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
125125
equal(target.text(), 'March 2012', 'Title is "March 2012"');
126126

127127
// Navigation: -1 month, shift + up arrow key
@@ -134,7 +134,7 @@ test('by month, v2 (shift + up/down arrows)', function(){
134134
datesEqual(this.dp.viewDate, UTCDate(2012, 1, 29));
135135
datesEqual(this.dp.date, UTCDate(2012, 1, 29));
136136
// Month not changed
137-
target = this.picker.find('.datepicker-days thead th.switch');
137+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
138138
equal(target.text(), 'February 2012', 'Title is "February 2012"');
139139

140140
// Navigation: +1 month, shift + down arrow key
@@ -146,15 +146,15 @@ test('by month, v2 (shift + up/down arrows)', function(){
146146
});
147147
datesEqual(this.dp.viewDate, UTCDate(2012, 3, 29));
148148
datesEqual(this.dp.date, UTCDate(2012, 3, 29));
149-
target = this.picker.find('.datepicker-days thead th.switch');
149+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
150150
equal(target.text(), 'April 2012', 'Title is "April 2012"');
151151
});
152152

153153
test('by year, v1 (ctrl + left/right arrows)', function(){
154154
var target;
155155

156156
equal(this.dp.viewMode, 0);
157-
target = this.picker.find('.datepicker-days thead th.switch');
157+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
158158
equal(target.text(), 'March 2012', 'Title is "March 2012"');
159159

160160
// Navigation: -1 year, ctrl + left arrow key
@@ -167,7 +167,7 @@ test('by year, v1 (ctrl + left/right arrows)', function(){
167167
datesEqual(this.dp.viewDate, UTCDate(2011, 2, 31));
168168
datesEqual(this.dp.date, UTCDate(2011, 2, 31));
169169
// Month not changed
170-
target = this.picker.find('.datepicker-days thead th.switch');
170+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
171171
equal(target.text(), 'March 2011', 'Title is "March 2011"');
172172

173173
// Navigation: +1 year, ctrl + right arrow key
@@ -179,15 +179,15 @@ test('by year, v1 (ctrl + left/right arrows)', function(){
179179
});
180180
datesEqual(this.dp.viewDate, UTCDate(2013, 2, 31));
181181
datesEqual(this.dp.date, UTCDate(2013, 2, 31));
182-
target = this.picker.find('.datepicker-days thead th.switch');
182+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
183183
equal(target.text(), 'March 2013', 'Title is "March 2013"');
184184
});
185185

186186
test('by year, v2 (ctrl + up/down arrows)', function(){
187187
var target;
188188

189189
equal(this.dp.viewMode, 0);
190-
target = this.picker.find('.datepicker-days thead th.switch');
190+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
191191
equal(target.text(), 'March 2012', 'Title is "March 2012"');
192192

193193
// Navigation: -1 year, ctrl + up arrow key
@@ -200,7 +200,7 @@ test('by year, v2 (ctrl + up/down arrows)', function(){
200200
datesEqual(this.dp.viewDate, UTCDate(2011, 2, 31));
201201
datesEqual(this.dp.date, UTCDate(2011, 2, 31));
202202
// Month not changed
203-
target = this.picker.find('.datepicker-days thead th.switch');
203+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
204204
equal(target.text(), 'March 2011', 'Title is "March 2011"');
205205

206206
// Navigation: +1 year, ctrl + down arrow key
@@ -212,15 +212,15 @@ test('by year, v2 (ctrl + up/down arrows)', function(){
212212
});
213213
datesEqual(this.dp.viewDate, UTCDate(2013, 2, 31));
214214
datesEqual(this.dp.date, UTCDate(2013, 2, 31));
215-
target = this.picker.find('.datepicker-days thead th.switch');
215+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
216216
equal(target.text(), 'March 2013', 'Title is "March 2013"');
217217
});
218218

219219
test('by year, v3 (ctrl + shift + left/right arrows)', function(){
220220
var target;
221221

222222
equal(this.dp.viewMode, 0);
223-
target = this.picker.find('.datepicker-days thead th.switch');
223+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
224224
equal(target.text(), 'March 2012', 'Title is "March 2012"');
225225

226226
// Navigation: -1 year, ctrl + left arrow key
@@ -234,7 +234,7 @@ test('by year, v3 (ctrl + shift + left/right arrows)', function(){
234234
datesEqual(this.dp.viewDate, UTCDate(2011, 2, 31));
235235
datesEqual(this.dp.date, UTCDate(2011, 2, 31));
236236
// Month not changed
237-
target = this.picker.find('.datepicker-days thead th.switch');
237+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
238238
equal(target.text(), 'March 2011', 'Title is "March 2011"');
239239

240240
// Navigation: +1 year, ctrl + right arrow key
@@ -247,15 +247,15 @@ test('by year, v3 (ctrl + shift + left/right arrows)', function(){
247247
});
248248
datesEqual(this.dp.viewDate, UTCDate(2013, 2, 31));
249249
datesEqual(this.dp.date, UTCDate(2013, 2, 31));
250-
target = this.picker.find('.datepicker-days thead th.switch');
250+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
251251
equal(target.text(), 'March 2013', 'Title is "March 2013"');
252252
});
253253

254254
test('by year, v4 (ctrl + shift + up/down arrows)', function(){
255255
var target;
256256

257257
equal(this.dp.viewMode, 0);
258-
target = this.picker.find('.datepicker-days thead th.switch');
258+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
259259
equal(target.text(), 'March 2012', 'Title is "March 2012"');
260260

261261
// Navigation: -1 year, ctrl + up arrow key
@@ -269,7 +269,7 @@ test('by year, v4 (ctrl + shift + up/down arrows)', function(){
269269
datesEqual(this.dp.viewDate, UTCDate(2011, 2, 31));
270270
datesEqual(this.dp.date, UTCDate(2011, 2, 31));
271271
// Month not changed
272-
target = this.picker.find('.datepicker-days thead th.switch');
272+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
273273
equal(target.text(), 'March 2011', 'Title is "March 2011"');
274274

275275
// Navigation: +1 year, ctrl + down arrow key
@@ -282,15 +282,15 @@ test('by year, v4 (ctrl + shift + up/down arrows)', function(){
282282
});
283283
datesEqual(this.dp.viewDate, UTCDate(2013, 2, 31));
284284
datesEqual(this.dp.date, UTCDate(2013, 2, 31));
285-
target = this.picker.find('.datepicker-days thead th.switch');
285+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
286286
equal(target.text(), 'March 2013', 'Title is "March 2013"');
287287
});
288288

289289
test('by year, from leap day', function(){
290290
var target;
291291

292292
equal(this.dp.viewMode, 0);
293-
target = this.picker.find('.datepicker-days thead th.switch');
293+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
294294

295295
this.input.val('29-02-2012').datepicker('update');
296296
datesEqual(this.dp.viewDate, UTCDate(2012, 1, 29));
@@ -307,7 +307,7 @@ test('by year, from leap day', function(){
307307
datesEqual(this.dp.viewDate, UTCDate(2011, 1, 28));
308308
datesEqual(this.dp.date, UTCDate(2011, 1, 28));
309309
// Month not changed
310-
target = this.picker.find('.datepicker-days thead th.switch');
310+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
311311
equal(target.text(), 'February 2011', 'Title is "February 2011"');
312312

313313
// Navigation: +1 year, back to leap year
@@ -319,7 +319,7 @@ test('by year, from leap day', function(){
319319
// Both updated on keyboard navigation; graceful month-end
320320
datesEqual(this.dp.viewDate, UTCDate(2012, 1, 28));
321321
datesEqual(this.dp.date, UTCDate(2012, 1, 28));
322-
target = this.picker.find('.datepicker-days thead th.switch');
322+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
323323
equal(target.text(), 'February 2012', 'Title is "February 2012"');
324324

325325
// Navigation: +1 year
@@ -331,15 +331,15 @@ test('by year, from leap day', function(){
331331
// Both updated on keyboard navigation; graceful month-end
332332
datesEqual(this.dp.viewDate, UTCDate(2013, 1, 28));
333333
datesEqual(this.dp.date, UTCDate(2013, 1, 28));
334-
target = this.picker.find('.datepicker-days thead th.switch');
334+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
335335
equal(target.text(), 'February 2013', 'Title is "February 2013"');
336336
});
337337

338338
test('Selection (enter)', function(){
339339
var target;
340340

341341
equal(this.dp.viewMode, 0);
342-
target = this.picker.find('.datepicker-days thead th.switch');
342+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
343343
equal(target.text(), 'March 2012', 'Title is "March 2012"');
344344

345345
// Navigation: -1 day, left arrow key
@@ -351,7 +351,7 @@ test('Selection (enter)', function(){
351351
datesEqual(this.dp.viewDate, UTCDate(2012, 2, 30));
352352
datesEqual(this.dp.date, UTCDate(2012, 2, 30));
353353
// Month not changed
354-
target = this.picker.find('.datepicker-days thead th.switch');
354+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
355355
equal(target.text(), 'March 2012', 'Title is "March 2012"');
356356

357357
// Selection: Enter
@@ -363,7 +363,7 @@ test('Selection (enter)', function(){
363363
datesEqual(this.dp.viewDate, UTCDate(2012, 2, 30));
364364
datesEqual(this.dp.date, UTCDate(2012, 2, 30));
365365
// Month not changed
366-
target = this.picker.find('.datepicker-days thead th.switch');
366+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
367367
equal(target.text(), 'March 2012', 'Title is "March 2012"');
368368

369369
ok(this.picker.is(':not(:visible)'), 'Picker is hidden');
@@ -373,7 +373,7 @@ test('Toggle hide/show (escape); navigation while hidden is suppressed', functio
373373
var target;
374374

375375
equal(this.dp.viewMode, 0);
376-
target = this.picker.find('.datepicker-days thead th.switch');
376+
target = this.picker.find('.datepicker-days thead th.datepicker-switch');
377377
equal(target.text(), 'March 2012', 'Title is "March 2012"');
378378

379379
ok(this.picker.is(':visible'), 'Picker is visible');

0 commit comments

Comments
 (0)