Commit 93baee1 1 parent b1dcf88 commit 93baee1 Copy full SHA for 93baee1
File tree 3 files changed +69
-0
lines changed
test/intl402/PluralRules/prototype/toStringTag
3 files changed +69
-0
lines changed Original file line number Diff line number Diff line change
1
+ // Copyright (C) 2020 Alexey Shvayka. All rights reserved.
2
+ // This code is governed by the BSD license found in the LICENSE file.
3
+
4
+ /*---
5
+ esid: sec-intl.pluralrules.prototype-tostringtag
6
+ description: >
7
+ Object.prototype.toString doesn't special-case neither Intl.PluralRules instances nor its prototype.
8
+ info: |
9
+ Object.prototype.toString ( )
10
+
11
+ [...]
12
+ 14. Else, let builtinTag be "Object".
13
+ 15. Let tag be ? Get(O, @@toStringTag).
14
+ 16. If Type(tag) is not String, set tag to builtinTag.
15
+ 17. Return the string-concatenation of "[object ", tag, and "]".
16
+ features: [Symbol.toStringTag]
17
+ ---*/
18
+
19
+ delete Intl . PluralRules . prototype [ Symbol . toStringTag ] ;
20
+
21
+ assert . sameValue ( Object . prototype . toString . call ( Intl . PluralRules . prototype ) , "[object Object]" ) ;
22
+ assert . sameValue ( Object . prototype . toString . call ( new Intl . PluralRules ( ) ) , "[object Object]" ) ;
Original file line number Diff line number Diff line change
1
+ // Copyright (C) 2020 Alexey Shvayka. All rights reserved.
2
+ // This code is governed by the BSD license found in the LICENSE file.
3
+
4
+ /*---
5
+ esid: sec-intl.pluralrules.prototype-tostringtag
6
+ description: >
7
+ Object.prototype.toString utilizes Intl.PluralRules.prototype[@@toStringTag].
8
+ info: |
9
+ Object.prototype.toString ( )
10
+
11
+ [...]
12
+ 14. Else, let builtinTag be "Object".
13
+ 15. Let tag be ? Get(O, @@toStringTag).
14
+ 16. If Type(tag) is not String, set tag to builtinTag.
15
+ 17. Return the string-concatenation of "[object ", tag, and "]".
16
+
17
+ Intl.PluralRules.prototype [ @@toStringTag ]
18
+
19
+ The initial value of the @@toStringTag property is the String value "Intl.PluralRules".
20
+ features: [Symbol.toStringTag]
21
+ ---*/
22
+
23
+ assert . sameValue ( Object . prototype . toString . call ( Intl . PluralRules . prototype ) , "[object Intl.PluralRules]" ) ;
24
+ assert . sameValue ( Object . prototype . toString . call ( new Intl . PluralRules ( ) ) , "[object Intl.PluralRules]" ) ;
Original file line number Diff line number Diff line change
1
+ // Copyright (C) 2020 Alexey Shvayka. All rights reserved.
2
+ // This code is governed by the BSD license found in the LICENSE file.
3
+
4
+ /*---
5
+ esid: sec-intl.pluralrules.prototype-tostringtag
6
+ description: >
7
+ Property descriptor of Intl.PluralRules.prototype[@@toStringTag].
8
+ info: |
9
+ Intl.PluralRules.prototype [ @@toStringTag ]
10
+
11
+ The initial value of the @@toStringTag property is the String value "Intl.PluralRules".
12
+
13
+ This property has the attributes { [[Writable]]: false, [[Enumerable]]: false, [[Configurable]]: true }.
14
+ features: [Symbol.toStringTag]
15
+ includes: [propertyHelper.js]
16
+ ---*/
17
+
18
+ verifyProperty ( Intl . PluralRules . prototype , Symbol . toStringTag , {
19
+ value : "Intl.PluralRules" ,
20
+ writable : false ,
21
+ enumerable : false ,
22
+ configurable : true ,
23
+ } ) ;
You can’t perform that action at this time.
0 commit comments