mirror of https://github.com/tc39/test262.git
generated test files
This commit is contained in:
parent
ea4c8fc95c
commit
2664e17e1d
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-expr-computed-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'constructor' (computed)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
ComputedPropertyName : [ AssignmentExpression ]
|
||||
Return empty.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : FieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
var x = "constructor";
|
||||
var C = class {
|
||||
[x];
|
||||
}
|
||||
|
||||
var c = new C();
|
||||
|
||||
assert.sameValue(c.hasOwnProperty("constructor"), true);
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-expr-computed-name.template
|
||||
/*---
|
||||
description: Static class field cannot have PropName 'constructor' (computed)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
ComputedPropertyName : [ AssignmentExpression ]
|
||||
Return empty.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
var x = "constructor";
|
||||
var C = class {
|
||||
static [x];
|
||||
}
|
||||
|
||||
var c = new C();
|
||||
|
||||
assert.sameValue(c.hasOwnProperty("constructor"), true);
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-prototype.case
|
||||
// - src/class-fields/propname-error/cls-expr-computed-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'prototype' (computed)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
ComputedPropertyName : [ AssignmentExpression ]
|
||||
Return empty.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
var x = "prototype";
|
||||
var C = class {
|
||||
static [x];
|
||||
}
|
||||
|
||||
var c = new C();
|
||||
|
||||
assert.sameValue(c.hasOwnProperty("prototype"), true);
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-expr-literal-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'constructor' (literal name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
LiteralPropertyName : IdentifierName
|
||||
Return StringValue of IdentifierName.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : FieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
var C = class {
|
||||
constructor;
|
||||
}
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-expr-literal-name.template
|
||||
/*---
|
||||
description: Static class field cannot have PropName 'constructor' (literal name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
LiteralPropertyName : IdentifierName
|
||||
Return StringValue of IdentifierName.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
var C = class {
|
||||
static constructor;
|
||||
}
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-prototype.case
|
||||
// - src/class-fields/propname-error/cls-expr-literal-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'prototype' (literal name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
LiteralPropertyName : IdentifierName
|
||||
Return StringValue of IdentifierName.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
var C = class {
|
||||
static prototype;
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-expr-string-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'constructor' (string name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
LiteralPropertyName:StringLiteral
|
||||
Return the String value whose code units are the SV of the StringLiteral.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : FieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
var C = class {
|
||||
'constructor';
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-expr-string-name.template
|
||||
/*---
|
||||
description: Static class field cannot have PropName 'constructor' (string name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
LiteralPropertyName:StringLiteral
|
||||
Return the String value whose code units are the SV of the StringLiteral.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
var C = class {
|
||||
static 'constructor';
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-prototype.case
|
||||
// - src/class-fields/propname-error/cls-expr-string-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'prototype' (string name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
LiteralPropertyName:StringLiteral
|
||||
Return the String value whose code units are the SV of the StringLiteral.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
var C = class {
|
||||
static 'prototype';
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-decl-computed-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'constructor' (computed)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
ComputedPropertyName : [ AssignmentExpression ]
|
||||
Return empty.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : FieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
var x = "constructor";
|
||||
class C {
|
||||
[x];
|
||||
}
|
||||
|
||||
var c = new C();
|
||||
|
||||
assert.sameValue(c.hasOwnProperty("constructor"), true);
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-decl-computed-name.template
|
||||
/*---
|
||||
description: Static class field cannot have PropName 'constructor' (computed)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
ComputedPropertyName : [ AssignmentExpression ]
|
||||
Return empty.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
var x = "constructor";
|
||||
class C {
|
||||
static [x];
|
||||
}
|
||||
|
||||
var c = new C();
|
||||
|
||||
assert.sameValue(c.hasOwnProperty("constructor"), true);
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-prototype.case
|
||||
// - src/class-fields/propname-error/cls-decl-computed-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'prototype' (computed)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
ComputedPropertyName : [ AssignmentExpression ]
|
||||
Return empty.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
var x = "prototype";
|
||||
class C {
|
||||
static [x];
|
||||
}
|
||||
|
||||
var c = new C();
|
||||
|
||||
assert.sameValue(c.hasOwnProperty("prototype"), true);
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-decl-literal-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'constructor' (literal name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
LiteralPropertyName : IdentifierName
|
||||
Return StringValue of IdentifierName.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : FieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
class C {
|
||||
constructor;
|
||||
}
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-decl-literal-name.template
|
||||
/*---
|
||||
description: Static class field cannot have PropName 'constructor' (literal name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
LiteralPropertyName : IdentifierName
|
||||
Return StringValue of IdentifierName.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
class C {
|
||||
static constructor;
|
||||
}
|
|
@ -0,0 +1,31 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-prototype.case
|
||||
// - src/class-fields/propname-error/cls-decl-literal-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'prototype' (literal name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
LiteralPropertyName : IdentifierName
|
||||
Return StringValue of IdentifierName.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
class C {
|
||||
static prototype;
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-decl-string-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'constructor' (string name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
LiteralPropertyName:StringLiteral
|
||||
Return the String value whose code units are the SV of the StringLiteral.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : FieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
class C {
|
||||
'constructor';
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-constructor.case
|
||||
// - src/class-fields/propname-error/cls-decl-string-name.template
|
||||
/*---
|
||||
description: Static class field cannot have PropName 'constructor' (string name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
LiteralPropertyName:StringLiteral
|
||||
Return the String value whose code units are the SV of the StringLiteral.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
class C {
|
||||
static 'constructor';
|
||||
}
|
|
@ -0,0 +1,32 @@
|
|||
// This file was procedurally generated from the following sources:
|
||||
// - src/class-fields/static-propname-prototype.case
|
||||
// - src/class-fields/propname-error/cls-decl-string-name.template
|
||||
/*---
|
||||
description: Static class fields cannot have PropName 'prototype' (string name)
|
||||
esid: sec-class-definitions-static-semantics-early-errors
|
||||
features: [class-fields]
|
||||
flags: [generated]
|
||||
negative:
|
||||
phase: early
|
||||
type: SyntaxError
|
||||
info: |
|
||||
Static Semantics: PropName
|
||||
...
|
||||
LiteralPropertyName:StringLiteral
|
||||
Return the String value whose code units are the SV of the StringLiteral.
|
||||
|
||||
|
||||
// This test file tests the following early error:
|
||||
Static Semantics: Early Errors
|
||||
|
||||
ClassElement : staticFieldDefinition;
|
||||
It is a Syntax Error if PropName of FieldDefinition is "prototype" or "constructor".
|
||||
|
||||
---*/
|
||||
|
||||
|
||||
throw "Test262: This statement should not be evaluated.";
|
||||
|
||||
class C {
|
||||
static 'prototype';
|
||||
}
|
Loading…
Reference in New Issue