Alexey Shvayka
cf37b039a8
Update Promise.all tests
2020-06-03 15:49:04 -04:00
Rick Waldron
081afde9c1
Promise.any: coverage updates, R3
2020-06-03 11:07:28 -07:00
Rick Waldron
9999dff8fd
Promise.any: coverage updates, R2
2020-06-03 11:07:28 -07:00
Rick Waldron
3604a65a29
Promise.any: coverage updates, R1
2020-06-03 11:07:28 -07:00
Marja Hölttä
218edad632
Remove duplicate Promise.all tests ( #2624 )
...
1) Promise/all/S25.4.4.1_A6.1_T1.js is the same as
Promise/all/S25.4.4.1_A2.1_T1.js
2) Promise/all/S25.4.4.1_A6.1_T2.js is covered by
Promise/all/S25.4.4.1_A2.3_T1.js and
Promise/all/S25.4.4.1_A2.3_T2.js
2020-05-18 10:42:56 -07:00
Marja Hölttä
429c60ec38
fix
2020-05-06 10:48:38 -04:00
Marja Hölttä
4be59efd30
fix
2020-05-06 10:48:38 -04:00
Marja Hölttä
affe579677
fix
2020-05-06 10:48:38 -04:00
Marja Hölttä
58dba42939
Add Promise/*/resolve-not-callable-close.js
2020-05-06 10:48:38 -04:00
Gus Caplan
4d9dccf443
Remove invalid feature, fix lint
2020-04-29 17:31:45 -04:00
jhnaldo
68205eb76c
Fixed wrong `esid` and `features` in a Promise.all test
2020-04-18 13:26:27 -04:00
Rick Waldron
772fd320cd
Promise.any: remove erroneous SpeciesConstructor tests until a better solution can be found. ( #2562 )
2020-03-31 13:51:49 -07:00
Rick Waldron
299cd74ef2
Promise.any: fix "invoke-then.js" test
2020-03-30 13:57:03 -04:00
Rick Waldron
22be03d833
Promise.any: lint fixes
2020-03-27 21:00:29 -04:00
Rick Waldron
d53f45db3d
Promise.any: remove unnecessary static resolve def
2020-03-25 12:25:56 -04:00
Rick Waldron
499b748dca
Promise.any: review fixes, 2
2020-03-25 12:14:32 -04:00
Rick Waldron
b21b0c1820
Promise.any: additional "resolve from rejection" tests
2020-03-25 12:04:37 -04:00
Rick Waldron
a05fb94eba
Promise.any: feature flags, 2
2020-03-25 12:04:37 -04:00
Rick Waldron
7fbce5a9d8
Promise.any: simplify promise creation
2020-03-25 12:04:37 -04:00
Rick Waldron
5c68b60ad3
Promise.any: cleanup in @@species tests
2020-03-25 12:04:37 -04:00
Rick Waldron
d9265df3ab
Promise.any: additional then + resolve tests
2020-03-25 12:04:37 -04:00
Rick Waldron
1c748507f2
Promise.any: feature flags
2020-03-25 12:04:36 -04:00
Rick Waldron
5d3eafc547
Promise.any: review fixes
2020-03-25 12:04:36 -04:00
Rick Waldron
6edaba378e
Promise.any: updates, corrections and new tests.
2020-03-25 12:04:36 -04:00
Rick Waldron
e0f0c7860b
Promise.any: empty iterable rejects with AggregateError
2020-03-25 12:04:36 -04:00
Rick Waldron
272e9abed4
Promise.any: make async operation test actually async
2020-03-25 12:04:36 -04:00
Rick Waldron
47b3858978
Promise.any: expected rejection shouldn't end with error message.
2020-03-25 12:04:36 -04:00
Rick Waldron
55b22d8d9f
Promise.any: string iterable should not be rejected (adds error message for clarity)
2020-03-25 12:04:36 -04:00
Rick Waldron
e0abeaa4df
Promise.any: convert sync test to async test to ensure run to completion
2020-03-25 12:04:36 -04:00
chicoxyzzy
860e02ad28
add iter-assigned tests
2020-03-25 12:04:36 -04:00
chicoxyzzy
9567abd85a
Add iter-arg tests
2020-03-25 12:04:36 -04:00
chicoxyzzy
094ddc7f75
add species-get-error test
2020-03-25 12:04:36 -04:00
chicoxyzzy
e3d48f244a
add Invocation of the instance's `then` method test
2020-03-25 12:04:35 -04:00
chicoxyzzy
afe3f0bb50
add reject-immed test
2020-03-25 12:04:35 -04:00
chicoxyzzy
adcd162c10
add is callable test
2020-03-25 12:04:35 -04:00
chicoxyzzy
88d058b59e
Add returns promise test
2020-03-25 12:04:35 -04:00
chicoxyzzy
be1bf6391e
Add Promise and Promise.any properties tests
2020-03-25 12:04:35 -04:00
chicoxyzzy
23d7f0b79d
add Invocation of the constructor's `resolve` method test
2020-03-25 12:04:35 -04:00
chicoxyzzy
f0fd4e0d4d
update features.txt
...
-
2020-03-25 12:04:35 -04:00
chicoxyzzy
aca10842a2
Add context tests
2020-03-25 12:04:35 -04:00
chicoxyzzy
715964b16b
Add Capability Executor tests
2020-03-25 12:04:35 -04:00
Gus Caplan
900855b07b
Fix Promise/prototype/finally/rejected-observable-then-calls-argument
2020-02-13 10:37:24 -05:00
Gus Caplan
505949357b
Fix call to $DONE
2020-02-08 08:55:38 -05:00
Rick Waldron
811090fce2
Fix: \$DONE() must not be called with an argument, unless the argument is an error.
2020-02-07 12:24:43 -05:00
Jordan Harband
0ebbdf0395
`Promise.prototype.finally` thunks have a length of 0
2020-02-07 11:44:31 -05:00
Alexey Shvayka
57d5ffa471
Fix $DONE usage
2020-02-05 15:05:51 -05:00
Alexey Shvayka
c5b1c97362
Fix isConstructor checks
2020-02-05 15:05:51 -05:00
Alexey Shvayka
b3ec56fb8c
Add CreateResolvingFunctions tests
2020-02-05 15:05:51 -05:00
Alexey Shvayka
8ce27898b9
Add Then Finally Functions test
2020-02-05 15:05:51 -05:00
Alexey Shvayka
1e13f2b1e7
Add Catch Finally Functions test
2020-02-05 15:05:51 -05:00
Alexey Shvayka
95fd012c66
Add isConstructor to Promise.prototype.finally test
2020-02-05 15:05:51 -05:00
Alexey Shvayka
71a70fc117
Use isConstructor in "executor-function-nonconstructor.js" ( #2393 )
2019-10-08 14:41:29 -04:00
Mike Pennisi
f26c2a11bd
Remove unnecessary "includes" directives
...
The values defined by the referenced files are not used by these tests.
This makes their inclusion superfluous, which needlessly increases the
time to execute the tests and may confuse some readers.
2019-09-25 13:59:24 -04:00
Alexey Shvayka
8042c57d9b
Add Promise#finally invoked on thenable test ( #2312 )
...
* Rename proxy context test
* Add thenable context test
2019-08-28 12:42:24 -03:00
André Bargull
59a1a016b7
Assign "name" property to all anonymous functions ( #2299 )
...
Implements the changes from <https://github.com/tc39/ecma262/pull/1490 >.
2019-08-15 10:58:40 -04:00
Leo Balter
ff9763729d
Remove duplicated es[56]id if esid is present
2019-08-05 10:54:37 -04:00
André Bargull
d8c20b423b
Call $DONE function exactly once per test
...
Also make a note in CONTRIBUTING.md that `$DONE` shouldn't be called multiple times.
2019-07-22 02:12:24 -07:00
Alexey Shvayka
d7c95efe66
Improve "name" tests of Promise built-in functions ( #2179 )
2019-06-26 15:03:14 -04:00
Gus Caplan
61ccff550e
Fix invoke-resolve-get-error-close tests ( #2210 )
2019-06-21 14:26:57 -04:00
Aleksey Shvayka
e4fed70c9b
Fix description of Promise constructor test ( #2174 )
2019-05-22 17:57:45 -04:00
Aleksey Shvayka
ee960aefb5
Improve Promise constructor coverage ( #2158 )
...
* Add constructor descriptor test
* Rename & improve non-callable executor test
* Rename & simplify executor call context tests
* Remove duplicate reject via abrupt test
* Deduplicate undefined NewTarget tests
* Add basic constructor test
* Add abrupt prototype getting tests
2019-05-22 17:33:09 -04:00
Leo Balter
3b2ad0b5d0
Fix tests for new resolve lookup in Promise.allSettled
2019-04-24 17:28:01 -04:00
Leo Balter
24d1b6d59c
Fix tests for new resolve lookup
2019-04-24 17:28:01 -04:00
Leo Balter
b646cf6365
Add tests for Promise.all|race resolve lookup
...
Ref tc39/ecma262#1506
2019-04-24 17:28:01 -04:00
Leo Balter
7e7b9e103d
Port tests from Promise.all to Promise.allSettled ( #2124 )
2019-04-17 14:17:54 -04:00
Rick Waldron
6d2288fe79
Eliminate false positives: Promise.prototype.finally
2018-11-30 09:34:25 -05:00
Adrian Heine
fc6de76a0d
Add missing mandatory Promise.{all,race} argument
2018-11-08 09:37:56 +01:00
André Bargull
500e48e6ce
Fix various test bugs ( #1502 )
...
Fixes #1492
2018-03-22 16:36:57 -04:00
Rick Waldron
03f0f56961
Promise.all/race with non-iterable or invalid return from Symbol.iterator. ( #1496 )
...
Fixes gh-1490
2018-03-19 14:01:36 -04:00
Rick Waldron
133dfa8793
built-ins/Promise/*: make all indentation consistent (depth & character) ( #1433 )
2018-02-15 15:11:21 -05:00
André Bargull
f95b56ab28
Revert "js-beautify: make all indentation consistent (depth & character) ( #1409 )" ( #1412 )
...
This reverts commit a01de4a722
.
2018-02-09 12:09:47 -05:00
Rick Waldron
a01de4a722
js-beautify: make all indentation consistent (depth & character) ( #1409 )
2018-02-09 11:35:37 -05:00
André Bargull
82c6148980
Add missing closing parenthesis and remove invalid async flag ( #1402 )
2018-02-01 14:04:51 -05:00
Jordan Harband
03da22868a
Promise.prototype.finally: add more tests
...
- per https://github.com/tc39/ecma262/pull/1083#issuecomment-361775023
2018-01-30 20:47:35 -05:00
Jordan Harband
7c5b5bf750
Promise.prototype.finally: add missing tests
...
Per:
- https://github.com/tc39/test262/issues/866#issuecomment-328565337
- https://github.com/tc39/test262/issues/866#issuecomment-359978873
Closes #866 .
2018-01-25 14:03:28 -05:00
André Bargull
f717982c94
Remove unused includes
2018-01-25 13:59:37 -05:00
Rick Waldron
66df349af3
Assert that promise callbacks were actually called. Closes #1328
...
Originally reported here: https://github.com/tc39/test262/pull/1328 , OP passed on revising.
2018-01-05 13:23:35 -05:00
Rick Waldron
92a2621901
Frontmatter: fixup "info: >" to "info: |"
2018-01-05 12:27:59 -05:00
Rick Waldron
4b4c44cb51
fixup: swap actual and expected in test/built-ins/Promise/prototype/finally/species-symbol.js ( #1333 )
2017-11-03 15:34:22 -04:00
Sathya Gunasekaran
a392f6ced8
Promise.p.finally: test SpeciesConstructor and Symbol.species lookup
2017-10-28 14:01:13 -07:00
Leo Balter
7cbbe51216
Add cross-realm feature
2017-09-22 15:29:10 -04:00
Jordan Harband
3528601c41
Promise.prototype.finally: add tests
2017-07-25 23:06:12 -07:00
Rick Waldron
86209d8fd9
Make all harness/* file names consistent; update occurrences in test
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2017-06-28 11:53:58 -04:00
Leo Balter
f6175af556
Add tests for Promises rejection queue ( #1029 )
...
* Add tests for Promises rejection queue
These basic tests assert the rejection is captured but a later queued job
from a chain of then calls.
* fixup! Add tests for Promises rejection queue
2017-05-10 12:59:18 -04:00
Mike Pennisi
a61efb5192
Add omitted license information
...
As the author of these files, I can verify that they were contributed in
2015 on behalf of the V8 project.
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
Rick Waldron
fdd2fa9b1c
Rename $ => $262. Fixes gh-802 ( #823 )
...
Signed-off-by: Rick Waldron <waldron.rick@gmail.com>
2017-03-01 16:34:15 -05:00
Kevin Gibbons
e6abf652d9
Ensure that tests calling $DONE have the async flag
2016-11-21 10:14:30 -05:00
Sathya
84e6ba81d0
Update context-non-object-with-promise.js ( #790 )
...
Promise constructor accepts only one executor function
2016-11-15 10:45:03 -08:00
jugglinmike
71e573f7da
Add tests for realm interactions ( #688 )
...
* Add tests for prototype realm inference
* Add tests for miscellaneous realm concerns
* Add tests for realm of spec-created Errors
In some cases, Error objects produced by the specification are
observable from ECMAScript code. Among these cases, some are further
differentiated in that they occur outside of any built-in function and
may be triggered through syntactic production directly. The current
realm record is commonly interpreted incorrectly under these
circumstances.
Add tests asserting that the expected realm record is used when
constructing such Error objects.
* Add tests for realm use in ArraySpeciesCreate
* Add tests for function realm retrieval
* Add tests for cross-realm behaviors of Symbols
* Add tests for GetValue and PutValue
* Add tests for realm of spec-created Arrays
In some cases, Arrays produced by CreateArrayFromList are observable
from ECMAScript code. Among these cases, two occur outside of any
built-in function and may be triggered through syntactic production
directly. The current realm record is commonly interpreted incorrectly
under these circumstances.
Add tests asserting that the expected realm record is used when
constructing arrays.
* Add test for spec-created object
* fixup! Add tests for realm of spec-created Errors
* fixup! Add tests for realm of spec-created Errors
* fixup! Add tests for prototype realm inference
* fixup! Add tests for miscellaneous realm concerns
2016-10-24 10:43:17 -07:00
Mike Pennisi
1ec40f349a
Re-write tests for Promise.prototype internal slots
...
The original implementation of the test for the absense of a
[[PromiseState]] internal slot did not actually assert the documented
semantics. Re-implement the test to rely on the IsPromise abstract
operation (via `Promise.prototype.then`) to accurately ensure that the
object does not have a [[PromiseState]] internal slot.
In relying on the semantics of the `instanceof` operator, the original
test for the [[Prototype]] internal slot was imprecise (the assertion
could be satisfied if additional objects were incorrectly defined on the
prototype chain). Re-write the test to assert the value of the
[[Prototype]] internal slot directly.
2016-06-27 15:31:01 -04:00
Mike Pennisi
cc7c77b9a1
Add test for Promise prototype property descriptor
2016-06-27 15:31:00 -04:00
Mike Pennisi
23659d6128
Extend coverage for `Promise.prototype.catch`
2016-06-27 15:31:00 -04:00
Mike Pennisi
12902b29c0
Add tests for invocation of Promise capability fns
2016-06-27 15:26:36 -04:00
Mike Pennisi
c62700c8ef
Assert iterator protocol for Promise methods
2016-06-27 15:26:35 -04:00
Mike Pennisi
2b5efe135c
Add test for abrupt completion during Promise.all
2016-06-27 15:19:48 -04:00
Mike Pennisi
b458d9bcc4
Add more tests for Promise resolution
...
Ensure that resolution is ignored for Promises that have already been
rejected.
2016-06-27 15:19:48 -04:00
Mike Pennisi
023ab45cf0
Extend tests for Promise resolve and reject fns
...
Assert expected return values in all cases.
2016-06-24 20:17:24 -04:00
Mike Pennisi
eb644bb2da
Reduce reliance on `fnGlobalObject.js`
...
This harness function is not necessary in the majority of cases in which
it is used. Remove its usage to simplify tests and decrease the amount
of domain-specific knowledge necessary to contribute to the test suite.
Persist the harness function itself for use by future tests for ES2015
modules (such a helper is necessary for tests that are interpreted as
module code).
2016-04-25 11:09:21 -07:00
Leo Balter
5357b1585b
Merge pull request #504 from bocoup/explicit-async
...
Make asynchronous test configuration explicit
2016-03-17 15:28:08 -04:00