@@ -13,6 +13,7 @@ test.snapshot({
13
13
'const foo = {[then]: 1}' ,
14
14
'const NOT_THEN = "no-then";const foo = {[NOT_THEN]: 1}' ,
15
15
'function foo({then}) {}' ,
16
+ '({[Symbol.prototype]: 1})' ,
16
17
17
18
// `class`
18
19
'class then {}' ,
@@ -35,6 +36,11 @@ test.snapshot({
35
36
'class Foo {static get #then() {}}' ,
36
37
'class Foo {static get [then]() {}}' ,
37
38
'class Foo {notThen = then}' ,
39
+ 'class Foo {[Symbol.property]}' ,
40
+ 'class Foo {static [Symbol.property]}' ,
41
+ 'class Foo {get [Symbol.property]() {}}' ,
42
+ 'class Foo {[Symbol.property]() {}}' ,
43
+ 'class Foo {static get [Symbol.property]() {}}' ,
38
44
39
45
// Assign
40
46
'foo[then] = 1' ,
@@ -46,6 +52,7 @@ test.snapshot({
46
52
'delete foo.then' ,
47
53
'typeof foo.then' ,
48
54
'foo.then != 1' ,
55
+ 'foo[Symbol.property] = 1' ,
49
56
50
57
// `Object.fromEntries`
51
58
'Object.fromEntries([then, 1])' ,
@@ -60,6 +67,7 @@ test.snapshot({
60
67
'Object.fromEntries([[..."then", 1]])' ,
61
68
'Object.fromEntries([["then", 1]], extraArgument)' ,
62
69
'Object.fromEntries(...[["then", 1]])' ,
70
+ 'Object.fromEntries([[Symbol.property, 1]])' ,
63
71
64
72
// `{Object,Reflect}.defineProperty`
65
73
'Object.defineProperty(foo, then, 1)' ,
@@ -71,6 +79,8 @@ test.snapshot({
71
79
'Object.defineProperty(foo, "then", )' ,
72
80
'Object.defineProperty(...foo, "then", 1)' ,
73
81
'Object.defineProperty(foo, ...["then", 1])' ,
82
+ 'Object.defineProperty(foo, Symbol.property, 1)' ,
83
+ 'Reflect.defineProperty(foo, Symbol.property, 1)' ,
74
84
75
85
// `export`
76
86
'export {default} from "then"' ,
0 commit comments