| Differences between
and this patch
- a/LayoutTests/ChangeLog +28 lines
Lines 1-3 a/LayoutTests/ChangeLog_sec1
1
2012-11-29  Keishi Hattori  <keishi@webkit.org>
2
3
        Add month-multiple-fields tests
4
        https://bugs.webkit.org/show_bug.cgi?id=102046
5
6
        Reviewed by NOBODY (OOPS!).
7
8
        Adding tests for multiple field <input type=month>.
9
10
        * fast/forms/month-multiple-fields/month-multiple-fields-ax-aria-attributes-expected.txt: Added.
11
        * fast/forms/month-multiple-fields/month-multiple-fields-ax-aria-attributes.html: Added.
12
        * fast/forms/month-multiple-fields/month-multiple-fields-ax-value-changed-notification-expected.txt: Added.
13
        * fast/forms/month-multiple-fields/month-multiple-fields-ax-value-changed-notification.html: Added.
14
        * fast/forms/month-multiple-fields/month-multiple-fields-blur-and-focus-events-expected.txt: Added.
15
        * fast/forms/month-multiple-fields/month-multiple-fields-blur-and-focus-events.html: Added.
16
        * fast/forms/month-multiple-fields/month-multiple-fields-change-layout-by-value-expected.txt: Added.
17
        * fast/forms/month-multiple-fields/month-multiple-fields-change-layout-by-value.html: Added.
18
        * fast/forms/month-multiple-fields/month-multiple-fields-mouse-events-expected.txt: Added.
19
        * fast/forms/month-multiple-fields/month-multiple-fields-mouse-events.html: Added.
20
        * fast/forms/month-multiple-fields/month-multiple-fields-preserve-value-after-history-back-expected.txt: Added.
21
        * fast/forms/month-multiple-fields/month-multiple-fields-preserve-value-after-history-back.html: Added.
22
        * fast/forms/month-multiple-fields/month-multiple-fields-reset-value-after-reloads-expected.txt: Added.
23
        * fast/forms/month-multiple-fields/month-multiple-fields-reset-value-after-reloads.html: Added.
24
        * fast/forms/month-multiple-fields/month-multiple-fields-spinbutton-change-and-input-events-expected.txt: Added.
25
        * fast/forms/month-multiple-fields/month-multiple-fields-spinbutton-change-and-input-events.html: Added.
26
        * fast/forms/month-multiple-fields/month-multiple-fields-wheel-event-expected.txt: Added.
27
        * fast/forms/month-multiple-fields/month-multiple-fields-wheel-event.html: Added.
28
1
2012-11-28  Mike West  <mkwst@chromium.org>
29
2012-11-28  Mike West  <mkwst@chromium.org>
2
30
3
        Add a test to ensure that 'seamless' iframes do not inherit contenteditable.
31
        Add a test to ensure that 'seamless' iframes do not inherit contenteditable.
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-ax-aria-attributes-expected.txt +16 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-ax-aria-attributes-expected.txt_sec1
1
This test checks aria-help attribute of fields in multiple fields week input UI.
2
3
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
4
5
6
Non-empty value
7
PASS focusedFieldValueDescription() is "AXHelp: Month, AXValueDescription: October, 1, 12"
8
PASS focusedFieldValueDescription() is "AXHelp: Year, AXValueDescription: 2012, 1, 275760"
9
Empty value
10
PASS focusedFieldValueDescription() is "AXHelp: Year, AXValueDescription: blank, 1, 275760"
11
PASS focusedFieldValueDescription() is "AXHelp: Month, AXValueDescription: blank, 1, 12"
12
13
PASS successfullyParsed is true
14
15
TEST COMPLETE
16
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-ax-aria-attributes.html +41 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-ax-aria-attributes.html_sec1
1
<!DOCTYPE html>
2
<html>
3
<head>
4
<script src="../../../fast/js/resources/js-test-pre.js"></script>
5
</head>
6
<body>
7
<input id="test" type="month" value="2012-10">
8
<script>
9
description('This test checks aria-help attribute of fields in multiple fields week input UI.');
10
11
function focusedFieldValueDescription()
12
{
13
    var element = accessibilityController.focusedElement;
14
    return element.helpText + ', ' +  element.valueDescription + ', ' + element.minValue + ', ' + element.maxValue;
15
}
16
17
var testInput = document.getElementById('test');
18
19
if (!window.accessibilityController || !window.eventSender)
20
    debug('Please run inside DRT or WTR.');
21
else {
22
    debug('Non-empty value');
23
    testInput.focus();
24
    shouldBeEqualToString('focusedFieldValueDescription()', 'AXHelp: Month, AXValueDescription: October, 1, 12');
25
    eventSender.keyDown('\t');
26
    shouldBeEqualToString('focusedFieldValueDescription()', 'AXHelp: Year, AXValueDescription: 2012, 1, 275760');
27
28
    debug('Empty value');
29
    eventSender.keyDown('\b');
30
    shouldBeEqualToString('focusedFieldValueDescription()', 'AXHelp: Year, AXValueDescription: blank, 1, 275760');
31
    eventSender.keyDown('\t', ['shiftKey']);
32
    eventSender.keyDown('\b');
33
    shouldBeEqualToString('focusedFieldValueDescription()', 'AXHelp: Month, AXValueDescription: blank, 1, 12');
34
35
    debug('');
36
    testInput.remove();
37
}
38
</script>
39
<script src="../../../fast/js/resources/js-test-post.js"></script>
40
</body>
41
</html>
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-ax-value-changed-notification-expected.txt +16 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-ax-value-changed-notification-expected.txt_sec1
1
This test checks value changed accessibility notifications.
2
3
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
4
5
6
FocusedUIElementChanged AXHelp: Month=AXValueDescription: October
7
FocusedUIElementChanged AXHelp: Year=AXValueDescription: 2012
8
ValueChanged AXHelp: Year=AXValueDescription: 0005
9
ValueChanged AXHelp: Year=AXValueDescription: 0005
10
ValueChanged AXHelp: Year=AXValueDescription: 0005
11
ValueChanged AXHelp: Year=AXValueDescription: 0005
12
13
PASS successfullyParsed is true
14
15
TEST COMPLETE
16
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-ax-value-changed-notification.html +38 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-ax-value-changed-notification.html_sec1
1
<!DOCTYPE html>
2
<html>
3
<head>
4
<script src="../../../fast/js/resources/js-test-pre.js"></script>
5
</head>
6
<body>
7
<input id="test" type="month" value="2012-10">
8
<script>
9
description('This test checks value changed accessibility notifications.');
10
11
var testInput = document.getElementById("test");
12
13
if (!window.accessibilityController || !window.eventSender)
14
    debug("Please run inside DRT or WRT.");
15
else {
16
    accessibilityController.addNotificationListener(function (element, notification) {
17
        if (notification == 'FocusedUIElementChanged' || notification == 'ValueChanged') {
18
            debug(notification + ' ' + element.helpText + '=' + element.valueDescription);
19
        }
20
    });
21
22
    testInput.focus();
23
    eventSender.keyDown('\t');
24
    eventSender.keyDown('4');
25
    eventSender.keyDown('upArrow');
26
27
    window.jsTestIsAsync = true;
28
29
    window.setTimeout(function() {
30
        debug('');
31
        testInput.remove();
32
        finishJSTest();
33
    }, 1);
34
}
35
</script>
36
<script src="../../../fast/js/resources/js-test-post.js"></script>
37
</body>
38
</html>
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-blur-and-focus-events-expected.txt +17 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-blur-and-focus-events-expected.txt_sec1
1
Check blur and focus events for multiple fields month input UI
2
3
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
4
5
6
focus() and blur()
7
PASS testInput.focus(); state() is "blur=0 focus=1"
8
PASS testInput.blur(); state() is "blur=1 focus=1"
9
focus and Tab key to blur
10
PASS keyDown("	"); state() is "blur=0 focus=1"
11
PASS keyDown("	"); state() is "blur=0 focus=1"
12
PASS keyDown("	"); state() is "blur=1 focus=1"
13
14
PASS successfullyParsed is true
15
16
TEST COMPLETE
17
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-blur-and-focus-events.html +12 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-blur-and-focus-events.html_sec1
1
<!DOCTYPE html>
2
<html>
3
<body>
4
<script src="../../js/resources/js-test-pre.js"></script>
5
<script src="../resources/multiple-fields-blur-and-focus-events.js"></script>
6
<div id="container"></div>
7
<script>
8
startTestFor('month');
9
</script>
10
<script src="../../js/resources/js-test-post.js"></script>
11
</body>
12
</html>
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-change-layout-by-value-expected.txt +11 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-change-layout-by-value-expected.txt_sec1
1
Change multiple fields week input UI layout by value
2
3
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
4
5
6
PASS widthOfEmptyValue < widthOfOverflowValue is true
7
PASS widthOfEmptyValue is widthOfValidValue
8
PASS successfullyParsed is true
9
10
TEST COMPLETE
11
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-change-layout-by-value.html +25 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-change-layout-by-value.html_sec1
1
<!DOCTYPE html>
2
<html>
3
<body>
4
<script src="../../js/resources/js-test-pre.js"></script>
5
<script>
6
description('Change multiple fields week input UI layout by value');
7
var testInput = document.createElement('input');
8
testInput.type = 'month';
9
testInput.max = '9999-12';
10
document.body.appendChild(testInput);
11
var widthOfEmptyValue = testInput.offsetWidth;
12
13
testInput.value = '10000-12';
14
var widthOfOverflowValue = testInput.offsetWidth;
15
shouldBeTrue('widthOfEmptyValue < widthOfOverflowValue');
16
17
testInput.value = '2012-10';
18
var widthOfValidValue = testInput.offsetWidth;
19
shouldBe('widthOfEmptyValue', 'widthOfValidValue');
20
21
testInput.remove();
22
</script>
23
<script src="../../js/resources/js-test-post.js"></script>
24
</body>
25
</html>
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-mouse-events-expected.txt +33 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-mouse-events-expected.txt_sec1
1
Multiple fields UI of month input type with mouse events
2
3
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
4
5
6
Please run this with DRT or WTR.
7
8
Test following mouse actions:
9
Mouse click to focus each of sub-fields
10
Mouse click on the spin button to update each of sub-fields
11
12
==> Focus on the month field.
13
PASS input.value is "2345-08"
14
PASS input.value is "2345-09"
15
PASS input.value is "2345-08"
16
PASS window.getSelection().rangeCount is 0
17
18
==> Focus on the year field.
19
PASS input.value is "2346-08"
20
PASS input.value is "2347-08"
21
PASS input.value is "2346-08"
22
PASS window.getSelection().rangeCount is 0
23
24
==> Click on a disabled field.
25
PASS input.value is "2346-08"
26
27
==> Click on a read-only field.
28
PASS input.value is "2346-08"
29
30
PASS successfullyParsed is true
31
32
TEST COMPLETE
33
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-mouse-events.html +83 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-mouse-events.html_sec1
1
<!DOCTYPE html>
2
<html>
3
<head>
4
<script src="../../js/resources/js-test-pre.js"></script>
5
</head>
6
<body>
7
<p id="description"></p>
8
<p>
9
Please run this with DRT or WTR.
10
</p>
11
Test following mouse actions:
12
<ul>
13
    <li>Mouse click to focus each of sub-fields</li>
14
    <li>Mouse click on the spin button to update each of sub-fields</li>
15
</ul>
16
<input id="input" type="month" style="font-family:ahem; font-size:16px;">
17
<div id="console"></div>
18
<script>
19
description('Multiple fields UI of month input type with mouse events');
20
var input = document.getElementById('input');
21
22
function keyDown(key, modifiers)
23
{
24
    if (!window.eventSender)
25
        return;
26
    eventSender.keyDown(key, modifiers);
27
}
28
29
function mouseClickOn(x, y)
30
{
31
    if (!window.eventSender)
32
        return;
33
    eventSender.mouseMoveTo(x + input.offsetLeft, y + input.offsetTop);
34
    eventSender.mouseDown();
35
    eventSender.mouseUp();
36
}
37
38
input.value = '2345-07';
39
var center = input.offsetHeight / 2;
40
var spinButtonOffset = 26;
41
42
debug('==> Focus on the month field.');
43
mouseClickOn(100, center);
44
keyDown('upArrow');
45
shouldBeEqualToString('input.value', '2345-08');
46
mouseClickOn(input.offsetWidth - spinButtonOffset, center - 1);
47
shouldBeEqualToString('input.value', '2345-09');
48
mouseClickOn(input.offsetWidth - spinButtonOffset, center + 1);
49
shouldBeEqualToString('input.value', '2345-08');
50
shouldBeZero('window.getSelection().rangeCount'); // No text selection.
51
52
debug('');
53
debug('==> Focus on the year field.');
54
mouseClickOn(220, center);
55
keyDown('upArrow');
56
shouldBeEqualToString('input.value', '2346-08');
57
mouseClickOn(input.offsetWidth - spinButtonOffset, center - 1);
58
shouldBeEqualToString('input.value', '2347-08');
59
mouseClickOn(input.offsetWidth - spinButtonOffset, center + 1);
60
shouldBeEqualToString('input.value', '2346-08');
61
shouldBeZero('window.getSelection().rangeCount'); // No text selection.
62
63
debug('');
64
debug('==> Click on a disabled field.');
65
input.disabled = true;
66
mouseClickOn(100, center);
67
keyDown('upArrow');
68
shouldBeEqualToString('input.value', '2346-08');
69
input.disabled = false;
70
71
debug('');
72
debug('==> Click on a read-only field.');
73
input.readOnly = true;
74
mouseClickOn(12, center);
75
keyDown('upArrow');
76
shouldBeEqualToString('input.value', '2346-08');
77
input.readOnly = false;
78
79
debug('');
80
</script>
81
<script src="../../js/resources/js-test-post.js"></script>
82
</body>
83
</html>
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-preserve-value-after-history-back-expected.txt +18 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-preserve-value-after-history-back-expected.txt_sec1
1
Checks input value is preserved after backward and forward
2
3
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
4
5
6
Went back to a page. Checking a form control which had a full value:
7
PASS "12012-10" is "12012-10"
8
Went back to a page. Checking a form control which had a partial value:
9
PASS "January ----" is "January ----"
10
Went forward to a page. Checking a form control which had a full value:
11
PASS "0001-11" is "0001-11"
12
Went forward to a page. Checking a form control which had a partial value:
13
PASS "--------- 1999" is "--------- 1999"
14
15
PASS successfullyParsed is true
16
17
TEST COMPLETE
18
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-preserve-value-after-history-back.html +141 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-preserve-value-after-history-back.html_sec1
1
<!DOCTYPE html>
2
<html>
3
<head>
4
<script src="../../../fast/js/resources/js-test-pre.js"></script>
5
</head>
6
<body>
7
<div id="container">
8
<input type="month" id="test1"><br>
9
<input type="month" id="test2" min="1999-01" max="1999-12"><br>
10
<iframe id="iframe"></iframe>
11
</div>
12
<script>
13
description('Checks input value is preserved after backward and forward');
14
if (!window.eventSender)
15
    debug('Please run within DRT/WTR');
16
window.jsTestIsAsync = true;
17
18
var iframe = document.getElementById('iframe');
19
var testInput1 = document.getElementById('test1');
20
var testInput2 = document.getElementById('test2');
21
var state = 'direct';
22
var pageName = location.search || '?page0';
23
var testCases = [];
24
25
function back(newState) {
26
    parent.state = newState;
27
    history.back();
28
}
29
30
function failed(message) {
31
    testFailed(message + ' in ' + state);
32
    finishJSTest();
33
}
34
35
function fieldsText(input) {
36
    if (!window.internals)
37
        return "";
38
    var editElement = window.internals.oldestShadowRoot(input);
39
    return editElement.textContent;
40
}
41
42
function finishTest() {
43
    runTestCases();
44
    document.body.removeChild(document.getElementById('container'));
45
    finishJSTest();
46
}
47
48
function forward(newState) {
49
    parent.state = newState;
50
    history.forward();
51
}
52
53
function keyDown(key, modifiers) {
54
    if (!window.eventSender)
55
        return;
56
    eventSender.keyDown(key, modifiers);
57
}
58
59
function runTestCases() {
60
    for (var index = 0; index < testCases.length; ++index) {
61
        var testCase = testCases[index];
62
        debug(testCase['description'] + ':');
63
        shouldBeEqualToString('"' + testCase['actual'] + '"', testCase['expected']);
64
    }
65
    debug('');
66
}
67
68
switch (pageName) {
69
case '?page0':
70
    iframe.src = location + '?page1';
71
    break;
72
73
case '?page1':
74
    switch (parent.state) {
75
    case 'direct': {
76
        testInput1.value = '12012-10';
77
        testInput2.focus();
78
        keyDown('upArrow'); // -> [October] 12012
79
        var nextUri = location.toString().replace('?page1', '?page2');
80
        setTimeout(function () { window.location.href = nextUri; }, 0);
81
        break;
82
    }
83
    case 'backTo1':
84
        parent.testCases.push(
85
            {
86
                'description' : 'Went back to a page. Checking a form control which had a full value',
87
                'actual' : testInput1.value,
88
                'expected' : '12012-10' },
89
            {
90
                'description' : 'Went back to a page. Checking a form control which had a partial value',
91
                'actual' : fieldsText(testInput2),
92
                'expected' : 'January ----'
93
            });
94
        forward('forwardTo2');
95
        break;
96
    case 'backTo1Second':
97
        parent.finishTest();
98
        break;
99
    default:
100
        failed('Unexpected state(' + parent.state + ')');
101
        break;
102
    }
103
    break;
104
105
case '?page2':
106
    switch (parent.state) {
107
    case 'direct':
108
        testInput1.value = '0001-11';
109
        testInput2.focus();
110
        keyDown('\t'); //        -> --------- [yyyy]
111
        keyDown('downArrow'); // -> --------- [1999]
112
        back('backTo1');
113
        break;
114
    case 'forwardTo2':
115
        parent.testCases.push(
116
            {
117
                'description' : 'Went forward to a page. Checking a form control which had a full value',
118
                'actual' : testInput1.value,
119
                'expected' : '0001-11'
120
            },
121
            {
122
                'description' : 'Went forward to a page. Checking a form control which had a partial value',
123
                'actual' : fieldsText(testInput2),
124
                'expected' : '--------- 1999'
125
            });
126
        back('backTo1Second');
127
        break;
128
    default:
129
        failed('Unexpected state(' + parent.state + ')');
130
        break;
131
    }
132
    break;
133
134
default:
135
    failed('Unexpected page(' + pageName + ')');
136
    break;
137
}
138
</script>
139
<script src="../../../fast/js/resources/js-test-post.js"></script>
140
</body>
141
</html>
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-reset-value-after-reloads-expected.txt +15 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-reset-value-after-reloads-expected.txt_sec1
1
Checks reloading page resets input values
2
3
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
4
5
6
Initial values:
7
PASS testInput1.value is ""
8
PASS testInput2.value is "1234-05"
9
Reloaded values:
10
PASS testInput1.value is ""
11
PASS testInput2.value is "1234-05"
12
PASS successfullyParsed is true
13
14
TEST COMPLETE
15
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-reset-value-after-reloads.html +42 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-reset-value-after-reloads.html_sec1
1
<!DOCTYPE html>
2
<html>
3
<head>
4
<script src="../../../fast/js/resources/js-test-pre.js"></script>
5
</head>
6
<body onload="runBodyLoaded()">
7
<iframe id=iframe srcdoc="<input type=month id='test1'><input type='month' id='test2' value='1234-05'>"></iframe>
8
<script>
9
description('Checks reloading page resets input values');
10
window.jsTestIsAsync = true;
11
12
var iframe = document.getElementById('iframe');
13
var testInput1;
14
var testInput2;
15
16
function runBodyLoaded()
17
{
18
    testInput1 = iframe.contentDocument.getElementById('test1');
19
    testInput2 = iframe.contentDocument.getElementById('test2');
20
    debug('Initial values:');
21
    shouldBeEqualToString('testInput1.value', '');
22
    shouldBeEqualToString('testInput2.value', '1234-05');
23
    testInput1.value = '2012-10';
24
    testInput2.value = '2012-11';
25
    iframe.addEventListener('load', parent.runOnIFrameLoad);
26
    iframe.contentWindow.location.reload();
27
}
28
29
function runOnIFrameLoad()
30
{
31
    testInput1 = iframe.contentDocument.getElementById('test1');
32
    testInput2 = iframe.contentDocument.getElementById('test2');
33
    debug('Reloaded values:');
34
    shouldBeEqualToString('testInput1.value', '');
35
    shouldBeEqualToString('testInput2.value', '1234-05');
36
    iframe.parentNode.removeChild(iframe);
37
    finishJSTest();
38
}
39
</script>
40
<script src="../../../fast/js/resources/js-test-post.js"></script>
41
</body>
42
</html>
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-spinbutton-change-and-input-events-expected.txt +19 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-spinbutton-change-and-input-events-expected.txt_sec1
1
Test for event dispatching by spin buttons in a type=month input.
2
3
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
4
5
6
Initial state
7
PASS changeEventCounter is 0
8
PASS inputEventCounter is 0
9
Click the upper button
10
PASS testInput.value is "2012-11"
11
PASS changeEventCounter is 1
12
PASS inputEventCounter is 1
13
Focus on another field
14
PASS changeEventCounter is 1
15
PASS inputEventCounter is 1
16
PASS successfullyParsed is true
17
18
TEST COMPLETE
19
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-spinbutton-change-and-input-events.html +14 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-spinbutton-change-and-input-events.html_sec1
1
<!DOCTYPE html>
2
<html>
3
<head>
4
<script src="../../../fast/js/resources/js-test-pre.js"></script>
5
<script src="../resources/common.js"></script>
6
<script src="../resources/common-spinbutton-change-and-input-events.js"></script>
7
</head>
8
<body>
9
<script>
10
testSpinButtonChangeAndInputEvents('month', '2012-10', '2012-11');
11
</script>
12
<script src="../../../fast/js/resources/js-test-post.js"></script>
13
</body>
14
</html>
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-wheel-event-expected.txt +23 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-wheel-event-expected.txt_sec1
1
Test for wheel operations for <input type=month>
2
3
On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE".
4
5
6
Initial value is 1999-01. We'll wheel up by 1:
7
PASS input.value is "1999-02"
8
Wheel up by 100:
9
PASS input.value is "1999-03"
10
Wheel down by 1:
11
PASS input.value is "1999-02"
12
Wheel down by 256:
13
PASS input.value is "1999-01"
14
Disabled input element:
15
PASS input.value is "1999-01"
16
Read-only input element:
17
PASS input.value is "1999-01"
18
No focus:
19
PASS input.value is "1999-01"
20
PASS successfullyParsed is true
21
22
TEST COMPLETE
23
- a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-wheel-event.html +17 lines
Line 0 a/LayoutTests/fast/forms/month-multiple-fields/month-multiple-fields-wheel-event.html_sec1
1
<!DOCTYPE html>
2
<html>
3
<head>
4
<script src="../../../fast/js/resources/js-test-pre.js"></script>
5
<script src="../resources/common-wheel-event.js"></script>
6
</head>
7
<body>
8
<script>
9
testWheelEvent({
10
    'inputType' : 'month',
11
    'initialValue' : '1999-01',
12
    'stepUpValue1' : '1999-02',
13
    'stepUpValue2' : '1999-03' });
14
</script>
15
<script src="../../../fast/js/resources/js-test-post.js"></script>
16
</body>
17
</html>

Return to Bug 102046