| 1 |
// Copyright 2009 the Sputnik authors. All rights reserved. |
| 2 |
// This code is governed by the BSD license found in the LICENSE file. |
| 3 |
|
| 4 |
/*--- |
| 5 |
info: Operator remove leading StrWhiteSpaceChar |
| 6 |
es5id: 15.1.2.3_A2_T8 |
| 7 |
es6id: 18.2.4 |
| 8 |
esid: sec-parsefloat-string |
| 9 |
description: "StrWhiteSpaceChar :: LS (U+2028)" |
| 10 |
---*/ |
| 11 |
|
| 12 |
//CHECK#1 |
| 13 |
if (parseFloat("\u20281.1") !== parseFloat("1.1")) { |
| 14 |
$ERROR('#1: parseFloat("\\u20281.1") === parseFloat("1.1"). Actual: ' + (parseFloat("\u20281.1"))); |
| 15 |
} |
| 16 |
|
| 17 |
//CHECK#2 |
| 18 |
if (parseFloat("\u2028\u2028-1.1") !== parseFloat("-1.1")) { |
| 19 |
$ERROR('#2: parseFloat("\\u2028\\u2028-1.1") === parseFloat("-1.1"). Actual: ' + (parseFloat("\u2028\u2028-1.1"))); |
| 20 |
} |
| 21 |
|
| 22 |
//CHECK#3 |
| 23 |
assert.sameValue(parseFloat("\u2028"), NaN); |