| OLD | NEW |
| 1 Tests for .valueAsNumber with <input type=number>. | 1 Tests for .valueAsNumber with <input type=number>. |
| 2 | 2 |
| 3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". | 3 On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE
". |
| 4 | 4 |
| 5 | 5 |
| 6 PASS valueAsNumberFor("0") is 0 | 6 PASS valueAsNumberFor("0") is 0 |
| 7 PASS valueAsNumberFor("0.2") is 0.2 | 7 PASS valueAsNumberFor("0.2") is 0.2 |
| 8 PASS valueAsNumberFor(".2") is 0.2 | 8 PASS valueAsNumberFor(".2") is 0.2 |
| 9 PASS valueAsNumberFor("10") is 10 | 9 PASS valueAsNumberFor("10") is 10 |
| 10 PASS valueAsNumberFor("01") is 1 | 10 PASS valueAsNumberFor("01") is 1 |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 PASS setValueAsNumberAndGetValue(-1.2) is "-1.2" | 40 PASS setValueAsNumberAndGetValue(-1.2) is "-1.2" |
| 41 PASS setValueAsNumberAndGetValue(1.2e10) is "12000000000" | 41 PASS setValueAsNumberAndGetValue(1.2e10) is "12000000000" |
| 42 PASS setValueAsNumberAndGetValue(1.2e-10) is "1.2e-10" | 42 PASS setValueAsNumberAndGetValue(1.2e-10) is "1.2e-10" |
| 43 PASS setValueAsNumberAndGetValue(1.2345678901234567e+38) is "1.2345678901234567e
+38" | 43 PASS setValueAsNumberAndGetValue(1.2345678901234567e+38) is "1.2345678901234567e
+38" |
| 44 PASS setValueAsNumberAndGetValue("-3.40282346e+38") is "-3.40282346e+38" | 44 PASS setValueAsNumberAndGetValue("-3.40282346e+38") is "-3.40282346e+38" |
| 45 PASS setValueAsNumberAndGetValue("-3.40282348e+38") threw exception InvalidState
Error: Failed to set the 'valueAsNumber' property on 'HTMLInputElement': The val
ue provided (-3.40282e+38) is outside the range (-3.40282e+38, 3.40282e+38).. | 45 PASS setValueAsNumberAndGetValue("-3.40282348e+38") threw exception InvalidState
Error: Failed to set the 'valueAsNumber' property on 'HTMLInputElement': The val
ue provided (-3.40282e+38) is outside the range (-3.40282e+38, 3.40282e+38).. |
| 46 PASS setValueAsNumberAndGetValue("3.40282346e+38") is "3.40282346e+38" | 46 PASS setValueAsNumberAndGetValue("3.40282346e+38") is "3.40282346e+38" |
| 47 PASS setValueAsNumberAndGetValue("3.40282348e+38") threw exception InvalidStateE
rror: Failed to set the 'valueAsNumber' property on 'HTMLInputElement': The valu
e provided (3.40282e+38) is outside the range (-3.40282e+38, 3.40282e+38).. | 47 PASS setValueAsNumberAndGetValue("3.40282348e+38") threw exception InvalidStateE
rror: Failed to set the 'valueAsNumber' property on 'HTMLInputElement': The valu
e provided (3.40282e+38) is outside the range (-3.40282e+38, 3.40282e+38).. |
| 48 Tests to set invalid values to valueAsNumber: | 48 Tests to set invalid values to valueAsNumber: |
| 49 PASS setValueAsNumberAndGetValue(null) is "0" | 49 PASS setValueAsNumberAndGetValue(null) is "0" |
| 50 PASS setValueAsNumberAndGetValue("foo") threw exception NotSupportedError: Faile
d to set the 'valueAsNumber' property on 'HTMLInputElement': The value provided
is not a number.. | 50 PASS setValueAsNumberAndGetValue("foo") is "" |
| 51 PASS setValueAsNumberAndGetValue(NaN) threw exception NotSupportedError: Failed
to set the 'valueAsNumber' property on 'HTMLInputElement': The value provided is
not a number.. | 51 PASS setValueAsNumberAndGetValue(NaN) is "" |
| 52 PASS setValueAsNumberAndGetValue(Number.NaN) threw exception NotSupportedError:
Failed to set the 'valueAsNumber' property on 'HTMLInputElement': The value prov
ided is not a number.. | 52 PASS setValueAsNumberAndGetValue(Number.NaN) is "" |
| 53 PASS setValueAsNumberAndGetValue(Infinity) threw exception NotSupportedError: Fa
iled to set the 'valueAsNumber' property on 'HTMLInputElement': The value provid
ed is infinite.. | 53 PASS setValueAsNumberAndGetValue(Infinity) threw exception TypeError: Failed to
set the 'valueAsNumber' property on 'HTMLInputElement': The value provided is in
finite.. |
| 54 PASS setValueAsNumberAndGetValue(Number.POSITIVE_INFINITY) threw exception NotSu
pportedError: Failed to set the 'valueAsNumber' property on 'HTMLInputElement':
The value provided is infinite.. | 54 PASS setValueAsNumberAndGetValue(Number.POSITIVE_INFINITY) threw exception TypeE
rror: Failed to set the 'valueAsNumber' property on 'HTMLInputElement': The valu
e provided is infinite.. |
| 55 PASS setValueAsNumberAndGetValue(Number.NEGATIVE_INFINITY) threw exception NotSu
pportedError: Failed to set the 'valueAsNumber' property on 'HTMLInputElement':
The value provided is infinite.. | 55 PASS setValueAsNumberAndGetValue(Number.NEGATIVE_INFINITY) threw exception TypeE
rror: Failed to set the 'valueAsNumber' property on 'HTMLInputElement': The valu
e provided is infinite.. |
| 56 PASS successfullyParsed is true | 56 PASS successfullyParsed is true |
| 57 | 57 |
| 58 TEST COMPLETE | 58 TEST COMPLETE |
| 59 | 59 |
| OLD | NEW |