Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit caa80c1

Browse files
committedMay 21, 2020
Adjust Intl.NumberFormat tests
1 parent b545bd9 commit caa80c1

File tree

2 files changed

+12
-4
lines changed

2 files changed

+12
-4
lines changed
 

‎test/intl402/NumberFormat/prototype/toStringTag/configurable.js

+11-3
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@
44
/*---
55
esid: sec-intl.numberformat.prototype-@@tostringtag
66
description: >
7-
Check that the initial value of the property is "Object" and that any changes
7+
Check that the initial value of the property is "Intl.NumberFormat" and that any changes
88
made by reconfiguring are reflected.
99
---*/
1010

11-
assert.sameValue(Intl.NumberFormat.prototype[Symbol.toStringTag], 'Object');
11+
assert.sameValue(Intl.NumberFormat.prototype[Symbol.toStringTag], 'Intl.NumberFormat');
1212
assert.sameValue(
1313
Object.prototype.toString.call(new Intl.NumberFormat()),
14-
'[object Object]'
14+
'[object Intl.NumberFormat]'
1515
);
1616

1717
Object.defineProperty(Intl.NumberFormat.prototype, Symbol.toStringTag, {
@@ -23,3 +23,11 @@ assert.sameValue(
2323
Object.prototype.toString.call(new Intl.NumberFormat()),
2424
'[object Alpha]'
2525
);
26+
27+
delete Intl.NumberFormat.prototype[Symbol.toStringTag];
28+
29+
assert.sameValue(Intl.NumberFormat.prototype[Symbol.toStringTag], undefined);
30+
assert.sameValue(
31+
Object.prototype.toString.call(new Intl.NumberFormat()),
32+
'[object Object]'
33+
);

‎test/intl402/NumberFormat/prototype/toStringTag/prop-desc.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ includes: [propertyHelper.js]
99
---*/
1010

1111
verifyProperty(Intl.NumberFormat.prototype, Symbol.toStringTag, {
12-
value: 'Object',
12+
value: 'Intl.NumberFormat',
1313
writable: false,
1414
enumerable: false,
1515
configurable: true

0 commit comments

Comments
 (0)
Please sign in to comment.