Commit Graph

803 Commits

Author SHA1 Message Date
Rick Waldron 85a4484c52 SuperProperty evaluation order
super[super()] should evaluate and resolve super() first
2018-05-24 15:10:35 -04:00
Rick Waldron 8579ac0356
Merge pull request #1565 from gibson042/2018-05-LineContinuation
Add tests for LineContinuation in StringLiteral
2018-05-21 15:45:12 -04:00
Richard Gibson 3758f6a97c Add tests for LineContinuation in StringLiteral 2018-05-21 12:19:48 -04:00
Caio Lima ebe393172f Adding prefixed string to compare with BigInt 2018-05-20 20:24:13 -03:00
Rick Waldron 1631fb76d1
Merge pull request #1551 from hotsphink/numident
Add test for numeric literal followed by identifier
2018-05-10 14:14:31 -04:00
Steve Fink fab08ab7a2 Add test for numeric literal followed by identifier 2018-05-09 15:45:52 -07:00
Rick Waldron ffc46a667c BigInt: cleanup assertion messages (#1549) 2018-05-09 18:14:09 -03:00
Rick Waldron c38bf8ba23
Merge pull request #1546 from caiolima/big-int-relational-symbol
Added tests for relational comparison among BigInt and Symbol
2018-05-09 15:42:10 -04:00
Caio Lima c93caac30b Updating error messages 2018-05-08 22:58:18 -03:00
Leo Balter 524e8e43a5
Merge pull request #1544 from gibson042/proposal-json-superset
Tests for proposal-json-superset
2018-05-08 15:33:33 -03:00
Richard Gibson dbc0c6b1cc Add json-superset feature 2018-05-08 14:19:44 -04:00
Caio Lima 5cacfaf64b Added tests of relational comparison among BigInt and boolean 2018-05-08 10:06:29 -03:00
Caio Lima 340dfba5dc Added tests for relational comparison among BigInt and Symbol 2018-05-08 09:34:34 -03:00
Richard Gibson ba124c31b2 Add tests for non-ASCII LineTerminator characters in string literals 2018-05-07 16:59:55 -04:00
Richard Gibson 48b4aa66af Remove no-longer-valid tests 2018-05-07 16:58:42 -04:00
Rick Waldron 3b7a456ddb
Merge pull request #1532 from anba/compat-new
Various test cases for cross-browser compliance bugs
2018-05-03 14:19:40 -04:00
André Bargull b552dad5cb Various test cases for cross-browser compliance bugs 2018-05-03 09:27:27 -07:00
Mike Pennisi e01a560648 Remove superfluous code from negative syntax tests
Because these files contain syntax errors, the code they contain is not
intended to be executed, and the runtime semantics are therefore
irrelevant. Simplify the files by removing the unnecessary code.
2018-04-27 22:04:23 -04:00
Rick Waldron 64cdeaf1ed Remove erroneous remnant $ERROR calls from negative SyntaxError tests 2018-04-26 13:39:36 -04:00
Rick Waldron 0b36f27000 Features: add missing "destructuring-binding" features; remove "default-arg" (#1521) 2018-04-24 14:52:19 -04:00
André Bargull a1faccdd41 Fix various test bugs
- "CannotSuspendMainAgent" feature was changed to "CanBlockIsFalse" flag
- Move annex-b tests into annex-b directory
- Update variable names in nonshared-int-views.js tests
- Move getReport() call in nan-for-timeout.js to avoid iloop
- Update BigInt constructor to match new semantics (tc39/proposal-bigint#138)
2018-04-24 09:52:35 -07:00
Rick Waldron a1a4e2b1b8 Corrections to sec-web-compat-evaldeclarationinstantiation and sec-web-compat-functiondeclarationinstantiation tests. Fixes gh-1364 (#1509) 2018-04-18 16:54:30 -04:00
Robin Templeton 34e7102b78 bigint comparison tests (#1513)
* relational comparison of bigint and string values

* additional tests for strings converted to NaN
2018-04-18 15:33:00 -04:00
Rick Waldron ee3a57ca23
Merge pull request #1507 from bakkot/field-ref-error
Add test for proposal-class-fields#92
2018-04-11 13:49:54 -04:00
Daniel Ehrenberg 73b8d9c773 Revert "Revert "Additional tests for QuantifiableAssertion" (#1458)" (#1459)
This reverts commit 173e98e00b.
2018-04-09 17:35:13 -04:00
Kevin Gibbons 49039979c8 Add test for double super for proposal-class-fields#92 2018-04-09 12:02:22 -07:00
Kevin Gibbons dba8d7cdc7 Add test for proposal-class-fields#92 2018-04-06 11:24:15 -07:00
Valerie 1e1d503c1b numeric literal seperators: test change in CodePoint production (#1464) 2018-02-28 13:58:22 -05:00
Daniel Ehrenberg 0b54908dba Add test for eval-in-function template tags (#1457)
Thanks to Caitin Potter for highlighting this test case.
2018-02-27 17:46:44 -05:00
Leo Balter 173e98e00b
Revert "Additional tests for QuantifiableAssertion" (#1458) 2018-02-26 10:12:09 -05:00
Daniel Ehrenberg 5b63d98a73
Merge pull request #1456 from littledan/quantifiedassertion
Additional tests for QuantifiableAssertion
2018-02-26 15:35:49 +01:00
Daniel Ehrenberg f9a0f05850 Additional tests for QuantifiableAssertion
- Tests that lookahead and lookbehind are not extended to
  QuantifiableAssertion, as in https://github.com/tc39/ecma262/pull/1102
- Additional tests verifying some more combinations of cases for
  QuantifiableAssertion being invalid in Unicode mode.

Based on the tests in https://chromium-review.googlesource.com/c/v8/v8/+/926102

These tests pass on V8 (if the throw for early errors is removed to
work around a V8 issue where RegExps don't have early errors).
2018-02-26 12:34:39 +01:00
Valerie R Young 7882fbfae3 async-iteration: move existing throw/return tests to AsyncGeneratorPrototype dir 2018-02-22 13:34:08 -05:00
Valerie R Young 0e99fa8a3a async-iteration: add esid for 'esid: pending' tests 2018-02-22 13:34:08 -05:00
Jeff Walden a19993e269 Add tests for the behavior of INT32_MIN (-2147483648) as exponent with the exponentiation operator and with Math.pow (which shares the same core algorithm in the spec, but might be differently implemented in actual implementations). (#1445) 2018-02-14 17:02:39 -05:00
Adrian Heine 2fb8eca677 Fix typo intialize(r) -> initialize(r) 2018-02-12 10:05:52 -05:00
Yusuke Suzuki 18c1e799a0 Prefer spaces to tabs if it is not syntax related tests
This patch changes tabs to spaces for newly added tests.
2018-02-08 13:32:42 -05:00
Rick Waldron 12797840ae features: [numeric-separator-literal] 2018-02-08 11:13:54 -05:00
Leo Balter 53c00784b6 Revert "Revert "Tests for NumericSeparatorLiteral. Closes gh-1051" (#1188)"
This reverts commit 8422147c17.
2018-02-08 11:13:54 -05:00
Daniel Ehrenberg d5fc8b25af Test for change to cache templates by site, not contents (#972)
* Test for change to cache templates by site, not contents

These tests are against a specification change based on discussion in
https://github.com/tc39/ecma262/issues/840

The tests here passed on SpiderMonkey but failed on other
implementations, which implement the current specification.

* Add a test that caching is by source location, not function identity

* Update existing tests to reference the spec properly
2018-02-05 14:40:19 -05:00
Leo Balter 31dfa8761a
Merge pull request #1404 from jugglinmike/refactor-for-parsers-function
Refactor function literal tests for parsers
2018-02-05 11:44:03 -05:00
Mike Pennisi 1d96e25784 Refactor function literal tests for parsers
A number of tests for the parsing of function literals were expressed
using `eval`. This made the tests more complex than necessary and also
prevented the tests from providing value to ECMAScript parsers.

Remove the use of `eval` in the relevant tests and instead express the
expectations with literal source text.
2018-02-03 23:25:41 -05:00
Mike Pennisi 6dafe71f1a Improve file names 2018-02-03 23:15:40 -05:00
Zirak 1bcb4fc2ef Fix typo in comments (Standart -> Standard) 2018-01-29 09:51:13 -05:00
Mike Pennisi baa5d94bc5 Refactor object initializer tests for parsers
A number of tests for the parsing of object initializers were expressed
using `eval`. This made the tests more complex than necessary and also
prevented the tests from providing value to ECMAScript parsers.

Remove the use of `eval` in the relevant tests and instead express the
expectations with literal source text.
2018-01-25 14:01:06 -05:00
Josh Wolfe 4455b1017e remove unnecessary method syntax 2018-01-25 14:00:43 -05:00
Josh Wolfe 9d066a8181 Order of evaluation tests for infix numeric operators 2018-01-25 14:00:43 -05:00
Josh Wolfe 186ec5d177 BigInt and Number type mismatch tests for infix operators 2018-01-25 14:00:10 -05:00
André Bargull cbe12a53e1 Remove duplicate esids 2018-01-25 13:59:37 -05:00
André Bargull f717982c94 Remove unused includes 2018-01-25 13:59:37 -05:00
André Bargull f3911d7ae4 Update remaining tests to use 'parse' instead of 'early' error phase 2018-01-25 13:59:37 -05:00
Rick Waldron 2cb0028bf1 Rename sec-delete-operator test, mark non-obvious syntax 2018-01-17 12:47:44 -05:00
Mike Pennisi c4e02a7a65 fixup! Refactor DeleteExpression tests for parsers 2018-01-17 12:35:12 -05:00
Mike Pennisi cae69a9775 Refactor DeleteExpression tests for parsers
A number of tests for the parsing of the DeleteExpression production
were expressed using `eval`. This made the tests more complex than
necessary, and also prevented the tests from providing value to
ECMAScript parsers.

Remove the use of `eval` in the relevant tests and instead express the
expectations with literal source text. Remove superfluous tests which
only differed in the runtime semantics of source text that could not be
evaluated due to syntax errors.
2018-01-17 12:35:12 -05:00
Rick Waldron b7afd3d00d Frontmatter: updates to ForIn/OfBodyEvaluation tests 2018-01-11 10:47:10 -05:00
Rick Waldron d7b5715e6c Fix: various lint fixes 2018-01-11 10:21:08 -05:00
Rick Waldron 4afc330363 Fix: various lint fixes 2018-01-10 17:29:48 -05:00
Rick Waldron b1aa569c84 Fix: esid sec-runtime-semantics-classdefinitionevaluation 2018-01-10 16:10:32 -05:00
Rick Waldron 670560f16b Fix: esid sec-generator-function-definitions 2018-01-10 16:04:16 -05:00
Rick Waldron 3be781c92d Fix: es6id -> esid sec-additional-syntax-numeric-literals 2018-01-10 16:01:45 -05:00
Rick Waldron bbf3301ff4 Fix: es6id -> esid sec-html-like-comments 2018-01-10 16:01:21 -05:00
Rick Waldron 5cd8e7bd53 Fix esid: static-semantics-hasproductionintailposition => sec-static-semantics-hascallintailposition 2018-01-10 15:44:56 -05:00
Rick Waldron e9e928babe Resolving conflicts in class-fields src templates 2018-01-05 15:31:17 -05:00
Mike Pennisi e6d674ef7a Rename negative test "phase" for module resolution 2018-01-05 15:17:51 -05:00
Mike Pennisi 136110378b Rename negative test "phase" for parsing
Early errors may result from parsing the source text of a test file, but
they may also result from parsing some other source text as referenced
through the ES2015 module syntax. The latter form of early error is not
necessarily detectable by ECMAScript parsers, however. Because of this,
the label "early" is not sufficiently precise for all Test262 consumers
to correctly interpret all tests.

Update the "phase" name of "early" to "parse" for all those negative
tests that describe errors resulting from parsing of the file's source
text directly. A forthcoming commit will update the remaining tests to
use a "phase" name that is more specific to module resolution.
2018-01-05 15:17:50 -05:00
Josh Wolfe 4f06f98771 Infix operator ToNumeric coercion tests for BigInt operands 2018-01-05 12:46:27 -05:00
Rick Waldron 89ac510488 Frontmatter: fixup "description: |" to "description: >" 2018-01-05 12:29:17 -05:00
Rick Waldron 92a2621901 Frontmatter: fixup "info: >" to "info: |" 2018-01-05 12:27:59 -05:00
Rick Waldron 06aaef8ecd Restore & update existing static class field cases/templates 2017-12-21 16:38:08 -05:00
Rick Waldron 53f847b1bc Remove static private/public fields unsupported tests. 2017-12-21 16:37:14 -05:00
Daniel Ehrenberg dc4db968f2 Add tests that public and private static fields are unsupported 2017-12-21 15:21:04 -05:00
Daniel Ehrenberg 2e042d9f9d Regenerate tests 2017-12-21 15:21:04 -05:00
Daniel Ehrenberg d50c33a5b3 Remove static fields tests
Static fields were broken up from instance fields and demoted to
Stage 2 in the November 2017 TC39 meeting. This patch removes the
test262 tests which test static class fields.
2017-12-21 15:21:04 -05:00
Rick Waldron 642d88377f
Merge pull request #1375 from jugglinmike/refactor-for-parsers-assignment
Refactor AssignmentExpression tests for parsers
2017-12-19 15:46:31 -05:00
Rick Waldron a801bdf786 Fix frontmatter 2017-12-19 15:42:57 -05:00
André Bargull 204afb7ba6 Add tests when continue triggers IteratorClose 2017-12-19 15:42:57 -05:00
André Bargull df1e5e7d44 Add more completion value tests for try-statements 2017-12-19 15:42:56 -05:00
André Bargull 6b8bd307d2 Test other-id-start/continue and vertical tilde in identifiers 2017-12-19 15:42:56 -05:00
André Bargull 5a4c067831 Test expression at the rhs of dot-MemberExpression is an IdentifierName 2017-12-19 15:42:56 -05:00
André Bargull f4151fdbc0 Add tests for TCO with eval and cross-realm cases 2017-12-19 15:42:56 -05:00
André Bargull d231b90ea8 Add tests for direct-eval calls with spread expressions 2017-12-19 15:42:56 -05:00
André Bargull 3ce00cf5e3 Add tests for uninitialized bindings when accessed through Object methods and for-in 2017-12-19 15:42:56 -05:00
Mike Pennisi 025b44f38c Refactor AssignmentExpression tests for parsers
A number of tests for the parsing of the AssignmentExpression production
were expressed using `eval`. This made the tests more complex than
necessary, and also prevented the tests from providing value to
ECMAScript parsers.

Remove the use of `eval` in the relevant tests and instead express the
expectations with literal source text. Remove superfluous "onlyStrict"
restriction from tests by declaring the probe binding prior to
assignment.
2017-12-10 15:59:11 -05:00
Daniel Ehrenberg c48cd085ae Remove some spurious blank lines
A few BigInt tests had a blank line in an inconvenient place which
breaks an old, possibly incorrect YAML parser used by V8's test262
test automation. The best fix is to deploy a new YAML parser, but
in the short term, this patch deletes the blank lines and lets
V8 understand the feature flags below. Related: #1370
2017-12-08 16:56:51 +01:00
Leo Balter 6f8c89dfd1
Update class public fields tags in non-generated test files 2017-11-28 13:02:21 -05:00
Leo Balter a488271931
Update class fields tags in non-generated test files 2017-11-28 12:59:27 -05:00
Leo Balter d142f75468
Regenerate tests 2017-11-28 12:49:12 -05:00
Leo Balter 77c70a514d
Merge pull request #1344 from leobalter/class-fields-same-name
Class fields with the same name
2017-11-28 10:35:27 -05:00
Isiah Meadows 6ca3634d1b Broken error message in test (#1358)
Fixes #1355
2017-11-28 10:34:04 -05:00
Rick Waldron 3981242226 Let paramVarEnv be NewDeclarativeEnvironment(originalEnv). (#1348)
Originally discovered by Cait Potter (@caitp), reported in irc.mozilla.org#jslang
2017-11-20 15:05:20 -05:00
Leo Balter 5b7b007af5
Generate tests 2017-11-15 14:33:23 -05:00
Leo Balter 076ecc38c6
Fix bugs reported in #1338 (#1339)
* Accessing `ta[0]` throws a TypeError.

* Fix array indices starting at 0 and property references

* Fix classfields templates for properly checking static propnames.

* Generate tests

* `assert.equal` is not defined

* Add missing includes

* Generate tests

* typo s/Avalue/42/

* fix whitespace

* Add missing var for strict mode

* Expand generated class fields tests for forbidden computed property name values

Ref https://github.com/tc39/test262/pull/1339#issuecomment-342830243

* derived classes have access to private names in base classes, if private names are in scope
2017-11-10 15:06:00 -05:00
Valerie R Young bef77dc144 classfields: PrivateFieldSet and PrivateFieldGet 2017-11-03 15:43:44 -04:00
Valerie R Young a6e9a4ea1a classfields: PrivateFieldAdd TypeError test 2017-11-03 15:43:44 -04:00
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
Rick Waldron 3bab611979 Merge pull request #1314 from thejoshwolfe/bitshift
BigInt bitshift operators
2017-10-26 11:31:36 -04:00
Rick Waldron cfdf7b1fd4 Merge pull request #1291 from rwaldron/typeof-fixups
typeof fixups
2017-10-26 11:26:31 -04:00
Rick Waldron af2e7767ff Merge pull request #1300 from thejoshwolfe/bitwise-infix
BigInt bitwise and, or, xor
2017-10-26 11:25:44 -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
Josh Wolfe 035e79610d switch small values to 0b notation 2017-10-23 21:56:00 -07:00
Josh Wolfe b4f121d866 BigInt bitshift operators 2017-10-23 21:40:22 -07: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
Josh Wolfe 96ba34c240 bigint bitwise and, or, xor 2017-10-18 12:14:13 -07: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
Rick Waldron 511ce3b2c1 typeof ... fixups 2017-10-17 13:12:03 -04:00
Daniel Ehrenberg 772fb79fd7 Merge pull request #1281 from cxielarko/bigint-bool-eq
ToPrimitive called without hint for boolean equality
2017-10-16 23:35:12 +02:00
Daniel Ehrenberg 68e9124927 Merge pull request #1283 from cxielarko/bigint-arithmetic
BigInt arithmetic tests
2017-10-16 21:55:00 +02:00
Rick Waldron 3c5c0eddc4 Merge pull request #1280 from cxielarko/bigint-typeof
typeof test for BigInt
2017-10-16 14:30:27 -04:00
Josh Wolfe 5b721a23b5 bitwise-not tests for BigInt (#1277) 2017-10-16 14:17:13 -04:00
Robin Templeton 609869638f [BigInt] arithmetic tests 2017-10-16 13:19:08 -04:00
Rick Waldron 9e3ff9a232 arguments object, non-strict immutable name binding fixup (#1278) 2017-10-16 13:01:32 -04:00
Robin Templeton a9092bdbdf [BigInt] ToPrimitive called without hint for equality 2017-10-16 12:57:33 -04:00
Robin Templeton 11cd9e4c34 [BigInt] typeof 2017-10-16 12:56:49 -04:00
Rick Waldron 5d4c667b27 test/language/literals/regexp/*: early error test fixups (#1276) 2017-10-16 12:46:28 -04:00
Josh Wolfe 0b5c39cf91 BigInt unary minus tests (#1269) 2017-10-12 16:55:22 -04:00
Leo Balter edfef8db55 Updates for let names as a LHS in for-in loops (#1271)
* Delete identifier-let-allowed-as-lefthandside-expression-non-strict.js

Fixes #1192

This is already covered by 8422147c17/test/language/statements/for-in/head-lhs-let.js (L27)

* restore for-in test
2017-10-12 15:27:15 -04:00
Leo Balter 9915c713c6 Merge pull request #1263 from thejoshwolfe/messages
Add messages to asserts and use mixed quotes instead of escapes
2017-10-06 12:34:04 -04:00
Josh Wolfe 5cffebca94 use mixed quotes to avoid escape sequences in messages 2017-10-06 02:28:46 -07:00
Josh Wolfe 30e192da57 add messages to relational comparison tests 2017-10-06 02:25:58 -07: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
Leo Balter 60c232b4d4 Merge pull request #1250 from caitp/AsyncFixesFor988
Update async iteration tests with respect to pending spec change
2017-10-04 11:58:37 -04:00
Josh Wolfe a88b08f3fe Increment/decrement tests for references to BigInt values (#1261) 2017-10-04 11:55:24 -04:00
Josh Wolfe 6443289089 Equality comparison tests for bigint (#1257) 2017-10-04 11:54:00 -04:00
Caitlin Potter 0881a6a2ad Generate tests 2017-10-04 11:24:27 +02:00
Josh Wolfe aca48e4dfd Improve coverage for BigInt relational comparison tests (#1251) 2017-10-02 15:40:32 -04:00
⭐caitp⭐ f3b5a1e4c0 Update iteration tests with respect to spec changes (#1248)
https://github.com/tc39/ecma262/pull/988 changes the iteration protocol
such that the "next" method is only loaded from the iterator object once
during the prologue of iteration, rather than during each step.
2017-09-27 17:59:41 -04:00
Caio Lima d41eb5d913 Added test case to consider rest ordering (#1242) 2017-09-26 17:02:42 -04:00
Leo Balter 249935bd37 Follow up for tagging tests with U+180E 2017-09-26 14:13:29 -04:00
Leo Balter 60782de95e Tag tests for U+180E and complete coverage for RegExp matching 2017-09-25 15:27:59 -04:00