Generate tests

This commit is contained in:
Rick Waldron 2020-09-25 13:40:56 -04:00
parent 4853f6d363
commit 21e97fb616
10 changed files with 160 additions and 10 deletions

View File

@ -5,7 +5,7 @@
description: Computed property name from condition expression (ComputedPropertyName in ClassExpression) description: Computed property name from condition expression (ComputedPropertyName in ClassExpression)
esid: prod-ComputedPropertyName esid: prod-ComputedPropertyName
features: [computed-property-names, top-level-await] features: [computed-property-names, top-level-await]
flags: [generated, module] flags: [generated, async, module]
info: | info: |
ClassExpression: ClassExpression:
classBindingIdentifier opt ClassTail classBindingIdentifier opt ClassTail
@ -33,6 +33,7 @@ info: |
ComputedPropertyName: ComputedPropertyName:
[ AssignmentExpression ] [ AssignmentExpression ]
---*/ ---*/
try {
let C = class { let C = class {
@ -72,3 +73,25 @@ assert.sameValue(
C[await 9] = 9, C[await 9] = 9,
9 9
); );
assert.sameValue(
c[String(await 9)],
9
);
assert.sameValue(
c[String(await 9)] = 9,
9
);
assert.sameValue(
C[String(await 9)],
9
);
assert.sameValue(
C[String(await 9)] = 9,
9
);
} catch (e) {
$DONE(e);
}
$DONE();

View File

@ -5,7 +5,7 @@
description: Computed property name from condition expression (ComputedPropertyName in ClassExpression) description: Computed property name from condition expression (ComputedPropertyName in ClassExpression)
esid: prod-ComputedPropertyName esid: prod-ComputedPropertyName
features: [computed-property-names, top-level-await] features: [computed-property-names, top-level-await]
flags: [generated, module] flags: [generated, async, module]
info: | info: |
ClassExpression: ClassExpression:
classBindingIdentifier opt ClassTail classBindingIdentifier opt ClassTail
@ -33,6 +33,7 @@ info: |
ComputedPropertyName: ComputedPropertyName:
[ AssignmentExpression ] [ AssignmentExpression ]
---*/ ---*/
try {
let C = class { let C = class {
@ -54,3 +55,16 @@ assert.sameValue(
C[await 9](), C[await 9](),
9 9
); );
assert.sameValue(
c[String(await 9)](),
9
);
assert.sameValue(
C[String(await 9)](),
9
);
} catch (e) {
$DONE(e);
}
$DONE();

View File

@ -5,7 +5,7 @@
description: Computed property name from condition expression (ComputedPropertyName in ClassExpression) description: Computed property name from condition expression (ComputedPropertyName in ClassExpression)
esid: prod-ComputedPropertyName esid: prod-ComputedPropertyName
features: [computed-property-names, top-level-await] features: [computed-property-names, top-level-await]
flags: [generated, module] flags: [generated, async, module]
info: | info: |
ClassExpression: ClassExpression:
classBindingIdentifier opt ClassTail classBindingIdentifier opt ClassTail
@ -33,6 +33,7 @@ info: |
ComputedPropertyName: ComputedPropertyName:
[ AssignmentExpression ] [ AssignmentExpression ]
---*/ ---*/
try {
let C = class { let C = class {
@ -51,3 +52,16 @@ assert.sameValue(
C[await 9], C[await 9],
9 9
); );
assert.sameValue(
c[String(await 9)],
9
);
assert.sameValue(
C[String(await 9)],
9
);
} catch (e) {
$DONE(e);
}
$DONE();

View File

@ -5,7 +5,7 @@
description: Computed property name from condition expression (ComputedPropertyName in ClassExpression) description: Computed property name from condition expression (ComputedPropertyName in ClassExpression)
esid: prod-ComputedPropertyName esid: prod-ComputedPropertyName
features: [computed-property-names, top-level-await] features: [computed-property-names, top-level-await]
flags: [generated, module] flags: [generated, async, module]
info: | info: |
ClassExpression: ClassExpression:
classBindingIdentifier opt ClassTail classBindingIdentifier opt ClassTail
@ -33,6 +33,7 @@ info: |
ComputedPropertyName: ComputedPropertyName:
[ AssignmentExpression ] [ AssignmentExpression ]
---*/ ---*/
try {
let C = class { let C = class {
@ -55,3 +56,16 @@ assert.sameValue(
C[await 9](), C[await 9](),
9 9
); );
assert.sameValue(
c[String(await 9)](),
9
);
assert.sameValue(
C[String(await 9)](),
9
);
} catch (e) {
$DONE(e);
}
$DONE();

View File

@ -5,7 +5,7 @@
description: Computed property name from condition expression (ComputedPropertyName in ObjectLiteral) description: Computed property name from condition expression (ComputedPropertyName in ObjectLiteral)
esid: prod-ComputedPropertyName esid: prod-ComputedPropertyName
features: [computed-property-names, top-level-await] features: [computed-property-names, top-level-await]
flags: [generated, module] flags: [generated, async, module]
info: | info: |
ObjectLiteral: ObjectLiteral:
{ PropertyDefinitionList } { PropertyDefinitionList }
@ -22,6 +22,7 @@ info: |
ComputedPropertyName: ComputedPropertyName:
[ AssignmentExpression ] [ AssignmentExpression ]
---*/ ---*/
try {
let o = { let o = {
@ -32,3 +33,12 @@ assert.sameValue(
o[await 9], o[await 9],
9 9
); );
assert.sameValue(
o[String(await 9)],
9
);
} catch (e) {
$DONE(e);
}
$DONE();

View File

@ -5,7 +5,7 @@
description: Computed property name from condition expression (ComputedPropertyName in ObjectLiteral) description: Computed property name from condition expression (ComputedPropertyName in ObjectLiteral)
esid: prod-ComputedPropertyName esid: prod-ComputedPropertyName
features: [computed-property-names, top-level-await] features: [computed-property-names, top-level-await]
flags: [generated, module] flags: [generated, async, module]
info: | info: |
ObjectLiteral: ObjectLiteral:
{ PropertyDefinitionList } { PropertyDefinitionList }
@ -22,6 +22,7 @@ info: |
ComputedPropertyName: ComputedPropertyName:
[ AssignmentExpression ] [ AssignmentExpression ]
---*/ ---*/
try {
let o = { let o = {
@ -32,3 +33,12 @@ assert.sameValue(
o[await 9], o[await 9],
9 9
); );
assert.sameValue(
o[String(await 9)],
9
);
} catch (e) {
$DONE(e);
}
$DONE();

View File

@ -5,7 +5,7 @@
description: Computed property name from condition expression (ComputedPropertyName in ClassDeclaration) description: Computed property name from condition expression (ComputedPropertyName in ClassDeclaration)
esid: prod-ComputedPropertyName esid: prod-ComputedPropertyName
features: [computed-property-names, top-level-await] features: [computed-property-names, top-level-await]
flags: [generated, module] flags: [generated, async, module]
info: | info: |
ClassExpression: ClassExpression:
classBindingIdentifier opt ClassTail classBindingIdentifier opt ClassTail
@ -33,6 +33,7 @@ info: |
ComputedPropertyName: ComputedPropertyName:
[ AssignmentExpression ] [ AssignmentExpression ]
---*/ ---*/
try {
class C { class C {
@ -72,3 +73,25 @@ assert.sameValue(
C[await 9] = 9, C[await 9] = 9,
9 9
); );
assert.sameValue(
c[String(await 9)],
9
);
assert.sameValue(
c[String(await 9)] = 9,
9
);
assert.sameValue(
C[String(await 9)],
9
);
assert.sameValue(
C[String(await 9)] = 9,
9
);
} catch (e) {
$DONE(e);
}
$DONE();

View File

@ -5,7 +5,7 @@
description: Computed property name from condition expression (ComputedPropertyName in ClassDeclaration) description: Computed property name from condition expression (ComputedPropertyName in ClassDeclaration)
esid: prod-ComputedPropertyName esid: prod-ComputedPropertyName
features: [computed-property-names, top-level-await] features: [computed-property-names, top-level-await]
flags: [generated, module] flags: [generated, async, module]
info: | info: |
ClassExpression: ClassExpression:
classBindingIdentifier opt ClassTail classBindingIdentifier opt ClassTail
@ -33,6 +33,7 @@ info: |
ComputedPropertyName: ComputedPropertyName:
[ AssignmentExpression ] [ AssignmentExpression ]
---*/ ---*/
try {
class C { class C {
@ -54,3 +55,16 @@ assert.sameValue(
C[await 9](), C[await 9](),
9 9
); );
assert.sameValue(
c[String(await 9)](),
9
);
assert.sameValue(
C[String(await 9)](),
9
);
} catch (e) {
$DONE(e);
}
$DONE();

View File

@ -5,7 +5,7 @@
description: Computed property name from condition expression (ComputedPropertyName in ClassExpression) description: Computed property name from condition expression (ComputedPropertyName in ClassExpression)
esid: prod-ComputedPropertyName esid: prod-ComputedPropertyName
features: [computed-property-names, top-level-await] features: [computed-property-names, top-level-await]
flags: [generated, module] flags: [generated, async, module]
info: | info: |
ClassExpression: ClassExpression:
classBindingIdentifier opt ClassTail classBindingIdentifier opt ClassTail
@ -33,6 +33,7 @@ info: |
ComputedPropertyName: ComputedPropertyName:
[ AssignmentExpression ] [ AssignmentExpression ]
---*/ ---*/
try {
let C = class { let C = class {
@ -51,3 +52,16 @@ assert.sameValue(
C[await 9], C[await 9],
9 9
); );
assert.sameValue(
c[String(await 9)],
9
);
assert.sameValue(
C[String(await 9)],
9
);
} catch (e) {
$DONE(e);
}
$DONE();

View File

@ -5,7 +5,7 @@
description: Computed property name from condition expression (ComputedPropertyName in ClassExpression) description: Computed property name from condition expression (ComputedPropertyName in ClassExpression)
esid: prod-ComputedPropertyName esid: prod-ComputedPropertyName
features: [computed-property-names, top-level-await] features: [computed-property-names, top-level-await]
flags: [generated, module] flags: [generated, async, module]
info: | info: |
ClassExpression: ClassExpression:
classBindingIdentifier opt ClassTail classBindingIdentifier opt ClassTail
@ -33,6 +33,7 @@ info: |
ComputedPropertyName: ComputedPropertyName:
[ AssignmentExpression ] [ AssignmentExpression ]
---*/ ---*/
try {
let C = class { let C = class {
@ -55,3 +56,16 @@ assert.sameValue(
C[await 9](), C[await 9](),
9 9
); );
assert.sameValue(
c[String(await 9)](),
9
);
assert.sameValue(
C[String(await 9)](),
9
);
} catch (e) {
$DONE(e);
}
$DONE();