Valerie R Young
ad12c4f5ad
classfields: field definition abrupt completion tests
2017-11-03 15:43:44 -04:00
Leo Balter
06091cb6fd
Merge pull request #1319 from bocoup/classfields-dupsdeletes
...
classfields: add tests duplicate private fields and deleting private fields
2017-11-03 15:19:34 -04:00
Valerie R Young
1bbedf4b02
regenerate files
2017-11-03 14:52:47 -04:00
Valerie R Young
dd371194fe
class fields: add ASI tests
2017-11-03 14:52:46 -04:00
Leo Balter
ce203360b1
Merge pull request #1323 from bocoup/classfields-scope
...
classfields: add early error tests for privatename references
2017-11-03 14:12:10 -04:00
Leo Balter
20a2572ba9
Merge pull request #1309 from bocoup/classfields-stringname
...
classfields: add tests for forbidden public/private propertynames
2017-11-03 14:02:27 -04:00
André Bargull
1f57fe412c
Regenerate tests
2017-11-01 08:23:44 -07:00
André Bargull
6c8698acac
Update test to not rely on throwing a Test262Error
...
Only this test relied on $ERROR throwing a catchable Test262Error.
This change allows test environments to provide their on $ERROR function for better error reporting.
2017-11-01 07:54:04 -07:00
Valerie R Young
4828ce08a3
regenerate files
2017-10-31 14:49:26 -04:00
Valerie R Young
7572c0c36b
Classfields: simple success case for nested classes private name reference
2017-10-29 20:46:09 -04:00
Valerie R Young
54f4d02aa6
Classfields: simple early errors test for privatename references in scripts
2017-10-29 20:46:09 -04:00
Valerie R Young
2664e17e1d
generated test files
2017-10-29 20:11:12 -04:00
Valerie R Young
ea4c8fc95c
classfields: add tests for forbidden privatenames
2017-10-27 17:40:42 -04:00
Leo Balter
88881301d7
Regenerate tests
2017-10-27 15:45:42 -04:00
Leo Balter
fafd465454
Merge pull request #1303 from bocoup/classfields
...
classfields: eval early errors
2017-10-27 12:03:18 -04:00
Leo Balter
b8d1a29f2d
Re-generate tests
2017-10-26 19:04:57 -04:00
Leo Balter
f8f5a7a1e7
Add missing generators flags
2017-10-26 19:04:57 -04:00
Valerie R Young
a9769d0854
regenerate test files
2017-10-26 10:10:57 -04:00
Valerie R Young
c39eeb9276
classfields: add tests for duplicate privatenames
2017-10-25 10:37:13 -04:00
Valerie R Young
0ad5eaf87c
regenerate tests
2017-10-20 22:06:02 -04:00
Valerie R Young
aeffe35d5b
regenerate test files
2017-10-18 16:50:39 -04:00
Valerie R Young
d3c7e1a13a
generate files
2017-10-17 17:53:03 -04:00
Leo Balter
315eca2bbd
Merge pull request #1293 from bocoup/esid-fix
...
fix: esid in case file instead of template file
2017-10-17 17:52:03 -04:00
Valerie R Young
d68faa904f
regenerate tests
2017-10-17 17:47:52 -04:00
Caitlin Potter
51e6a124d3
Generate tests
2017-10-17 15:48:40 -04:00
Leo Balter
b3092c61b6
Add generators flags for tests depending on generators features ( #1259 )
...
* Add missing generators feature flags
* Generate files
* Add generators flags
* fixup! Add generators flags
2017-10-04 16:12:34 -04:00
Caitlin Potter
0881a6a2ad
Generate tests
2017-10-04 11:24:27 +02:00
Leo Balter
7f88a6d7f9
Add other missing Symbol feature flags
2017-09-08 10:13:50 -04:00
Leo Balter
9f526c0bcd
Re-generate tests
2017-09-08 10:13:50 -04:00
Leo Balter
7630235d5d
Re-generate tests
2017-09-08 10:13:36 -04:00
Leo Balter
c41faf1aca
Add missing Symbol features flags
2017-09-07 15:51:13 -04:00
Leo Balter
391ce890b8
Merge pull request #1205 from anba/class-fields-fixes
...
Misc. class fields fixes
2017-09-05 11:16:19 -04:00
André Bargull
76ff88ff2f
Regenerate tests
2017-09-04 09:42:06 -04:00
André Bargull
672cfcf220
Regenerate tests
2017-09-01 23:45:01 +02:00
Leo Balter
a7ccd3042b
Generate tests
2017-08-24 14:11:28 -04:00
Rick Waldron
dffbe50668
Generate tests
2017-08-16 15:11:44 -04:00
Rick Waldron
144d73ef27
Generate tests
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2017-06-28 12:10:19 -04:00
Mike Pennisi
ef76e548a4
Re-generate tests
2017-06-28 11:24:36 -04:00
Mike Pennisi
81d00def42
Force "early error" tests to fail if evaluated
...
This pattern makes expectations more explicit by making test files more
literal.
2017-06-28 11:24:36 -04:00
Rick Waldron
2dd8e8b2c4
Throw away tests
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2017-06-23 13:21:39 -04:00
Leo Balter
5f04d2b1f3
Generate tests
2017-05-10 14:08:35 -04:00
Leo Balter
ed714d702a
Merge pull request #1017 from anba/expr-lookahead-restr
...
Expression statement lookahead restriction and identifier tests
2017-05-09 18:38:11 -04:00
Leo Balter
9481020e91
Merge pull request #1023 from anba/redeclaration
...
Lexical redeclarations in block- and switch-statements
Background feedback from @anba:
In https://tc39.github.io/ecma262/#sec-switch-statement-static-semantics-lexicallydeclarednames , all lexically declared names from the different case clauses are combined.
For each case clause, the LexicallyDeclaredNames definition from https://tc39.github.io/ecma262/#sec-block-static-semantics-lexicallydeclarednames applies, which has:
```
StatementListItem : Declaration
1. Return the BoundNames of Declaration.
```
And in https://tc39.github.io/ecma262/#prod-Declaration we've got:
```
Declaration[Yield, Await] : HoistableDeclaration[?Yield, ?Await, ~Default]
```
And in https://tc39.github.io/ecma262/#prod-HoistableDeclaration :
```
HoistableDeclaration[Yield, Await, Default] : FunctionDeclaration[?Yield, ?Await, ?Default]
```
And the BoundNames of a FunctionDeclaration is its BindingIdentifier https://tc39.github.io/ecma262/#sec-function-definitions-static-semantics-boundnames .
And there's also B3.3.5 (https://tc39.github.io/ecma262/#sec-switch-duplicates-allowed-static-semantics ) which allows duplicate FunctionDeclarations in sloppy mode in switch-statements.
2017-05-05 13:04:26 -04:00
André Bargull
c8e808bc69
Generate new tests for redeclarations in block- and switch-statements
2017-05-04 09:29:39 -07:00
Joseph Pecoraro
19eb1d2e02
Add tests for completion value of function / class declaration statements ( #1012 )
2017-05-04 11:22:28 -04:00
André Bargull
e0c29310d9
Generate tests for yield and await as identifier
2017-05-02 12:09:33 -07:00
André Bargull
490b2dc461
Remove manual tests for 'yield' in generators
2017-05-02 12:09:32 -07:00
André Bargull
3d8fe2af4c
Add tests for contextual keywords with escape sequences
2017-05-02 12:09:29 -07:00
Leo Balter
d74f58cddd
Generate tests
2017-04-21 15:26:46 -04:00
Leo Balter
20d496729d
Rename src/params to src/function-forms
...
The templates are being used for many tests reusing the same available function forms.
The format they are provided allow us to extend tests with cases for other tests relying
in the same formats.
2017-04-21 15:03:46 -04:00
Mike Pennisi
2c0c3e7f96
Correct typo in copyright information
2017-04-18 12:23:22 -04:00
André Bargull
d59e30c95e
Remove execute bit from files ( #976 )
2017-04-13 16:24:07 -04:00
Caitlin Potter
53ab9ffd4e
Generate tests
2017-04-10 18:29:53 -04:00
Daniel Ehrenberg
20536eabe1
Generate tests
2017-04-06 19:44:14 -04:00
Leo Balter
883db87a51
Generate tests
2017-04-06 15:33:33 -04:00
Leo Balter
f48a41caed
Generate tests
2017-04-06 12:36:50 -04:00
Rick Waldron
818bb8d88f
Merge pull request #938 from leobalter/yield-star-abrupt-getiter
...
Add cases for abrupt completions in yield* in async generator - getIterator
2017-04-06 11:43:29 -04:00
Rick Waldron
d7f4f5f664
Merge pull request #937 from leobalter/yield-star
...
templates for yield star flow
2017-04-06 11:43:21 -04:00
Rick Waldron
7685eeac1f
Merge pull request #941 from leobalter/yield-star-next-abrupt
...
Add cases for abrupt completions in yield* in async generator - next
2017-04-06 11:42:54 -04:00
Rick Waldron
01ce88b588
Merge pull request #922 from leobalter/async-gen-templates-dstr-errors
...
Add async generator error templates for destructuring binding
2017-04-06 11:42:04 -04:00
Rick Waldron
b0e921ff45
Merge pull request #921 from leobalter/async-gen-templates-dstr
...
Add async generator templates for destructing binding
2017-04-06 11:41:27 -04:00
Leo Balter
70870dc239
Generate tests
2017-03-27 21:44:04 -04:00
Leo Balter
8f0fd88ad9
Generate tests
2017-03-27 20:41:11 -04:00
Leo Balter
088ef77000
Generate tests
2017-03-27 17:19:19 -04:00
Leonardo Balter
1e74cfe336
Generate tests
2017-03-27 13:32:05 -04:00
Leo Balter
2adebecbfa
Generate tests
2017-03-27 13:21:14 -04:00
Leo Balter
3d7ae07295
Generate tests
2017-03-27 13:07:11 -04:00
Leonardo Balter
8525cdb165
Generate tests
2017-03-27 13:07:09 -04:00
Leonardo Balter
66f42efc99
Generate tests
2017-03-27 13:07:08 -04:00
Leonardo Balter
74b07de387
Generate tests
2017-03-27 13:07:06 -04:00
Leonardo Balter
4459447eb7
Generate tests
2017-03-27 13:01:11 -04:00
Leonardo Balter
285888ada1
Generate tests
2017-03-27 12:54:18 -04:00
Leonardo Balter
aa2c69960d
Generate tests
2017-03-14 15:13:10 -04:00
Leonardo Balter
7522a29f31
Generate tests
2017-03-14 14:58:33 -04:00
Leonardo Balter
c37a242057
Move tests for params trailing comma to the test gen tool
2017-03-14 14:58:32 -04:00
Leonardo Balter
c017b4280b
Generate tests
2017-03-14 13:30:35 -04:00
Rick Waldron
b0e9db8856
Remove invalid tests on parameters vs arguments list
...
Ref #822
2017-03-14 13:20:10 -04:00
Leonardo Balter
0cc55bb44d
Generate tests
2017-03-06 16:25:14 -05:00
Mike Pennisi
f03c2c244c
Procedurally generate related tests
...
Take advantage of a recent extension to the test generation tool in
order to limit duplication.
2017-03-04 12:17:35 -05:00
Leo Balter
4546006977
Merge pull request #855 from anba/fix-async-sab-class-tests
...
Change tests for `extends null` and Intl legacy constructor semantics
Ref tc39/ecma262#781
Ref tc39/ecma402#84
2017-03-01 15:56:41 -05:00
Mike Pennisi
37d5f8e5ef
Re-generate tests
2017-03-01 11:38:11 -05:00
Mike Pennisi
228851fbe4
Add tests for accessor names
2017-03-01 11:38:10 -05:00
André Bargull
7e94b8b7ac
Fix executor arguments validation in Promise subclass test
2017-02-22 18:05:08 +01:00
André Bargull
c16359bc3c
Update tests for classes extending null
...
Per https://github.com/tc39/ecma262/pull/781
2017-02-22 18:04:43 +01:00
Adam Klein
4ff7e4342e
Fix test for instantiating a class extending null ( #813 )
...
The sameValue assertion should be that the [[Prototype]] is
equal to the class's prototype, not the constructor.
2016-12-28 17:18:19 -08:00
Kevin Gibbons
3b9953d65c
remove last usage of arguments.caller ( #812 )
2016-12-28 10:54:02 -08:00
Kevin Gibbons
fcc9e07265
Add test for extending a constructor with null .prototype ( #806 )
2016-12-21 01:30:06 -05:00
Josh Wolfe
4fd91d8904
fix incorrect tests for trailing commas ( #787 )
2016-11-11 09:44:38 -08:00
Mike Pennisi
7d4b1d28ae
Re-format tests for SyntaxErrors
...
Authored via the following command:
$ find test -type f -print0 | \
xargs -0 sed \
-i 's/^\(\s*\)negative:\s*SyntaxError\s*$/\1negative:\n\1 phase: early\n\1 type: SyntaxError/g'
2016-10-19 15:24:21 -04:00
Mike Pennisi
cdc62ce0fa
Re-generate tests
2016-10-19 15:24:20 -04:00
Brian Terlson
dbf251586e
Add tests for async functions
...
Closes #479
2016-07-28 15:11:28 -07:00
Jeff Morrison
b785fdf942
Tests for trailing commas in function arg lists ( #733 )
...
Adds tests for the proposal as described here:
http://jeffmo.github.io/es-trailing-function-commas/
2016-07-28 12:32:03 -07:00
jugglinmike
35206ee85b
Add test for subclassing bound functions ( #720 )
...
The semantics under test have been incorrectly implemented by the
SpiderMonkey engine.
2016-07-11 13:46:03 -07:00
jugglinmike
da0a8e33f0
Improve coverage for section 14: Functions and Classes ( #717 )
...
* Add tests for early errors in functions
* Improve tests for class accessors
Use the `propertyHelper.js` utility in order to functionally test the
property descriptors of class methods.
* Remove redundant tests
The semantics of an IdentifierReference as a PropertyDefinition within
an object initializer are exhaustively tested by the files in this
directory whose name match the pattern `prop-def-id-*.js`.
Delete the redundant tests in favor of the more descriptively-named and
more exhaustive alternatives.
* Rename tests
* Update test names to be more descriptive
* Add tests for property descriptors of accessors
* Add tests for runtime error during method dfn
* Add test for observable iteration
2016-07-08 18:43:32 -07:00
jugglinmike
2bfaa0d895
Improve coverage for class "name" inference ( #718 )
...
* Extend tests for class "name" inference
Ensure that when a class defines a static "name" method, that method
definition prevents the "name" inference behavior.
* Re-generate tests
2016-07-08 18:37:04 -07:00
Leonardo Balter
c204c30a54
Remove invalid test from ArrayBuffer subclassing
...
Fixes gh-696
As pointed in gh-696, the ArrayBuffer ctor won't throw a RangeError when
invoked without arguments.
Instead of fixing the invalid assertion, this commit removes it as the
coverage for subclassing is already satisfied by the use of slice.
2016-07-05 16:29:21 -04:00
Mike Pennisi
655a880852
Add tests for arguments obj with dflt parameters
2016-06-21 12:22:49 -04:00
Mike Pennisi
7e3019e382
Add tests for function length with dflt parameters
2016-06-21 12:22:49 -04:00
Mike Pennisi
7dcccfcca6
Add tests for use of `yield` in default parameters
2016-06-21 12:22:48 -04:00
Mike Pennisi
e5f1740411
Generate tests
2016-06-21 12:22:48 -04:00
Mike Pennisi
a969e853e7
Generate tests
2016-06-21 12:20:36 -04:00
jugglinmike
dee1526ca7
Update tests concerning null-extending classes ( #658 )
...
The latest revision of ECMA262 makes special provisions for classes
which extend the `null` value [1]. Update the relevant tests
accordingly.
[1] https://github.com/tc39/ecma262/issues/543
2016-06-10 15:10:32 -04:00
Leo Balter
8f23cd6775
Merge pull request #607 from bocoup/envs
...
Add tests for Lexical Environment management
2016-05-30 16:13:33 -04:00
Mike Pennisi
d4b263ccbb
Generate tests
2016-05-10 11:57:37 -04:00
Mike Pennisi
74d0c1d124
Add equivalent tests for fn param-body boundary
...
These tests are based on the files introduced in the commit titled, "Add
tests for Lexical Environment management."
2016-04-28 09:47:18 -04:00
Mike Pennisi
3b3bd06819
Add tests for Lexical Environment management
...
Add tests that assert the management of the running execution context's
LexicalEnvironment and VariableEnvironment components, as created by the
following abstract operations:
- NewDeclarativeEnvironment
- NewObjectEnvironment
- NewFunctionEnvironment
Many tests require the use of non-strict direct eval, meaning they may
not be run in strict mode. This does not effect coverage because the
semantics in these cases are not observable from strict mode code.
Some situations require the creation of a binding, but this binding has
no relevance to the test itself. In these cases, use names consisting
solely of the underscore character (`_`).
Avoid the use of Block statements wherever possible, as these trigger
the creation of additional environments which may interfere with the
behavior under test.
2016-04-28 09:44:41 -04:00
Mike Pennisi
73a7e23061
Re-generate tests
2016-04-26 16:13:32 -04:00
Leo Balter
3723e7caeb
Merge pull request #545 from bocoup/generation
...
Introduce test generation tool
2016-04-15 17:56:36 -04:00
Mike Pennisi
74bff6b3d5
Add initial set of generated test sources
2016-03-16 15:29:30 -04:00
André Bargull
2acbd3e98e
Improve coverage for default class constructors
2016-03-01 19:15:21 +01:00
Leonardo Balter
d9a277aa7c
Fix location based return value for Date on subclassing tests
...
Fixes #489
2016-02-22 13:53:43 -05:00
Leonardo Balter
42d1a10d6d
fixup! Add tests for Array - calling super with a single argument
2016-01-13 13:28:00 -05:00
Leonardo Balter
c99ace29d7
Move subclass tests to test/language/statements/class/subclass/builtin-objects
2016-01-12 16:45:03 -05:00
Mike Pennisi
2fe074134a
Add tests for function `name` attribute
...
This change set includes tests for most invocations of the
SetFunctionName abstract operation in the ES2015 specification.
Practical testing considerations preclude the introduction of tests for
certain invocations:
- The project is still vetting methods to sustainably test the semantics
of the Destructuring Binding pattern across all valid productions.
- 13.3.3.6 Runtime Semantics: IteratorBindingInitialization
- 13.3.3.7 Runtime Semantics: KeyedBindingInitialization
- Without a loader, there is no way to access a function object declared
in an ExportDeclaration, so `name` assignment cannot be tested in
these cases
- 14.1.19 Runtime Semantics: InstantiateFunctionObject
- 14.4.12 Runtime Semantics: InstantiateFunctionObject
- 14.5.15 Runtime Semantics: BindingClassDeclarationEvaluation
- 15.2.3.11 Runtime Semantics: Evaluation
2015-07-21 20:05:34 -04:00
Mike Pennisi
10e0d977ec
Prefer explicit error checking where possible
...
The `negative` frontmatter tag expresses an expectation for the behavior
of the test file as a whole. The `assert.throws` helper function offers
more fine-grained control over expectations because it may be applied to
specific statements and expressions. This makes it preferable in cases
where it may be used (i.e. when the test body does not describe a syntax
error or early error).
Re-implement assertions for errors to use the `assert.throws` helper
function wherever possible.
2015-07-10 14:12:57 -04:00
Mike Pennisi
6646d3e94f
Re-organize class tests
...
The `test/language/class/` directory contains a small subset of
Test262's tests for ES2015 classes. The majority of tests for classes
are organized within `test/language/statements/class/`.
- Move the tests that rely on the ClassDeclaration syntactic form from
`test/language/class/` to `test/language/statements/class/`.
- Move the test that relies on the ClassExpression syntactic form from
`test/language/class/` to `test/language/expressions/class/`.
2015-07-10 10:36:05 -04:00
Rick Waldron
29e2990d9b
14.5 Class Definitions
...
- 14.5.1 Static Semantics: Early Errors
- 14.5.3 Static Semantics: ConstructorMethod
- 14.5.14 Runtime Semantics: ClassDefinitionEvaluation
2015-05-02 14:06:57 -04:00