Update the test for negative zero in NumberFormat.

The specification was updated in https://github.com/tc39/ecma402/pull/232.
This commit is contained in:
Ms2ger 2018-07-06 17:29:17 +02:00
parent e9a5a7f918
commit 65f2d5e8c2
1 changed files with 6 additions and 1 deletions

View File

@ -6,6 +6,11 @@ es5id: 11.3.2_FN_1
description: >
Tests that Intl.NumberFormat.prototype.format doesn't treat all
numbers as negative.
info: |
PartitionNumberPattern ( numberFormat, x )
1. If x is not NaN and x < 0 or _x_ is -0, then
a. Let _x_ be -_x_.
b. Let _pattern_ be _numberFormat_.[[NegativePattern]].
author: Roozbeh Pournader
---*/
@ -13,4 +18,4 @@ var formatter = new Intl.NumberFormat();
assert.notSameValue(formatter.format(1), formatter.format(-1), 'Intl.NumberFormat is formatting 1 and -1 the same way.');
assert.sameValue(formatter.format(-0), formatter.format(0), 'Intl.NumberFormat is formatting signed zeros differently.');
assert.notSameValue(formatter.format(0), formatter.format(-0), 'Intl.NumberFormat is formatting 0 and -0 the same way.');