mirror of
https://github.com/tc39/test262.git
synced 2025-04-08 19:35:28 +02:00
Regenerate tests
This commit is contained in:
parent
f810ad2550
commit
76ff88ff2f
test/language
expressions
async-generator
named-yield-promise-reject-next-yield-star-async-iterator.jsyield-promise-reject-next-yield-star-async-iterator.js
class
async-gen-method-static-yield-promise-reject-next-yield-star-async-iterator.jsasync-gen-method-yield-promise-reject-next-yield-star-async-iterator.js
object/method-definition
statements
async-generator
class
async-gen-method-static-yield-promise-reject-next-yield-star-async-iterator.jsasync-gen-method-yield-promise-reject-next-yield-star-async-iterator.js
for-await-of
async-func-decl-dstr-array-elem-put-const.jsasync-func-decl-dstr-array-elem-trlg-iter-elision-iter-nrml-close-null.jsasync-gen-decl-dstr-array-elem-iter-rtrn-close-null.jsasync-gen-decl-dstr-array-elem-put-const.jsasync-gen-decl-dstr-array-elem-trlg-iter-elision-iter-nrml-close-null.jsasync-gen-decl-dstr-array-elem-trlg-iter-rest-nrml-close-skip.js
@ -42,6 +42,6 @@ iter.next().then(() => {
|
||||
assert.sameValue(done, true, "The value of IteratorResult.done is `true`");
|
||||
assert.sameValue(value, undefined, "The value of IteratorResult.value is `undefined`");
|
||||
}).then($DONE, $DONE);
|
||||
}).then($DONE, $DONE);
|
||||
}, $DONE).catch($DONE);
|
||||
|
||||
assert.sameValue(callCount, 1);
|
||||
|
@ -42,6 +42,6 @@ iter.next().then(() => {
|
||||
assert.sameValue(done, true, "The value of IteratorResult.done is `true`");
|
||||
assert.sameValue(value, undefined, "The value of IteratorResult.value is `undefined`");
|
||||
}).then($DONE, $DONE);
|
||||
}).then($DONE, $DONE);
|
||||
}, $DONE).catch($DONE);
|
||||
|
||||
assert.sameValue(callCount, 1);
|
||||
|
@ -49,6 +49,6 @@ iter.next().then(() => {
|
||||
assert.sameValue(done, true, "The value of IteratorResult.done is `true`");
|
||||
assert.sameValue(value, undefined, "The value of IteratorResult.value is `undefined`");
|
||||
}).then($DONE, $DONE);
|
||||
}).then($DONE, $DONE);
|
||||
}, $DONE).catch($DONE);
|
||||
|
||||
assert.sameValue(callCount, 1);
|
||||
|
@ -49,6 +49,6 @@ iter.next().then(() => {
|
||||
assert.sameValue(done, true, "The value of IteratorResult.done is `true`");
|
||||
assert.sameValue(value, undefined, "The value of IteratorResult.value is `undefined`");
|
||||
}).then($DONE, $DONE);
|
||||
}).then($DONE, $DONE);
|
||||
}, $DONE).catch($DONE);
|
||||
|
||||
assert.sameValue(callCount, 1);
|
||||
|
@ -42,6 +42,6 @@ iter.next().then(() => {
|
||||
assert.sameValue(done, true, "The value of IteratorResult.done is `true`");
|
||||
assert.sameValue(value, undefined, "The value of IteratorResult.value is `undefined`");
|
||||
}).then($DONE, $DONE);
|
||||
}).then($DONE, $DONE);
|
||||
}, $DONE).catch($DONE);
|
||||
|
||||
assert.sameValue(callCount, 1);
|
||||
|
@ -42,6 +42,6 @@ iter.next().then(() => {
|
||||
assert.sameValue(done, true, "The value of IteratorResult.done is `true`");
|
||||
assert.sameValue(value, undefined, "The value of IteratorResult.value is `undefined`");
|
||||
}).then($DONE, $DONE);
|
||||
}).then($DONE, $DONE);
|
||||
}, $DONE).catch($DONE);
|
||||
|
||||
assert.sameValue(callCount, 1);
|
||||
|
@ -49,6 +49,6 @@ iter.next().then(() => {
|
||||
assert.sameValue(done, true, "The value of IteratorResult.done is `true`");
|
||||
assert.sameValue(value, undefined, "The value of IteratorResult.value is `undefined`");
|
||||
}).then($DONE, $DONE);
|
||||
}).then($DONE, $DONE);
|
||||
}, $DONE).catch($DONE);
|
||||
|
||||
assert.sameValue(callCount, 1);
|
||||
|
@ -49,6 +49,6 @@ iter.next().then(() => {
|
||||
assert.sameValue(done, true, "The value of IteratorResult.done is `true`");
|
||||
assert.sameValue(value, undefined, "The value of IteratorResult.value is `undefined`");
|
||||
}).then($DONE, $DONE);
|
||||
}).then($DONE, $DONE);
|
||||
}, $DONE).catch($DONE);
|
||||
|
||||
assert.sameValue(callCount, 1);
|
||||
|
@ -35,3 +35,8 @@ async function fn() {
|
||||
}
|
||||
|
||||
let promise = fn();
|
||||
|
||||
promise.then(() => $DONE('Promise incorrectly fulfilled.'), ({ constructor }) => {
|
||||
assert.sameValue(iterCount, 0);
|
||||
assert.sameValue(constructor, TypeError);
|
||||
}).then($DONE, $DONE);
|
||||
|
@ -76,3 +76,9 @@ async function fn() {
|
||||
}
|
||||
|
||||
let promise = fn();
|
||||
|
||||
promise.then(() => $DONE('Promise incorrectly fulfilled.'), ({ constructor }) => {
|
||||
assert.sameValue(iterCount, 0);
|
||||
assert.sameValue(nextCount, 2);
|
||||
assert.sameValue(constructor, TypeError);
|
||||
}).then($DONE, $DONE);
|
||||
|
@ -24,6 +24,12 @@ info: |
|
||||
lhs using AssignmentPattern as the goal symbol.
|
||||
[...]
|
||||
|
||||
AssignmentElement : DestructuringAssignmentTarget Initializer
|
||||
1. If DestructuringAssignmentTarget is neither an ObjectLiteral nor an ArrayLiteral, then
|
||||
a. Let lref be the result of evaluating DestructuringAssignmentTarget.
|
||||
b. ReturnIfAbrupt(lref).
|
||||
[...]
|
||||
|
||||
ArrayAssignmentPattern : [ AssignmentElementList ]
|
||||
|
||||
[...]
|
||||
@ -61,7 +67,12 @@ async function * fn() {
|
||||
|
||||
let iter = fn();
|
||||
|
||||
iter.next().then(() => $DONE('Promise incorrectly fulfilled.'), ({ constructor }) => {
|
||||
assert.sameValue(unreachable, 0);
|
||||
assert.sameValue(constructor, TypeError);
|
||||
}).then($DONE, $DONE);
|
||||
iter.next().then(result => {
|
||||
assert.sameValue(result.value, undefined);
|
||||
assert.sameValue(result.done, false);
|
||||
|
||||
iter.return().then(() => $DONE('Promise incorrectly fulfilled.'), ({ constructor }) => {
|
||||
assert.sameValue(unreachable, 0);
|
||||
assert.sameValue(constructor, TypeError);
|
||||
}).then($DONE, $DONE);
|
||||
}, $DONE).catch($DONE);
|
||||
|
@ -35,3 +35,8 @@ async function * fn() {
|
||||
}
|
||||
|
||||
let promise = fn().next();
|
||||
|
||||
promise.then(() => $DONE('Promise incorrectly fulfilled.'), ({ constructor }) => {
|
||||
assert.sameValue(iterCount, 0);
|
||||
assert.sameValue(constructor, TypeError);
|
||||
}).then($DONE, $DONE);
|
||||
|
@ -76,3 +76,9 @@ async function * fn() {
|
||||
}
|
||||
|
||||
let promise = fn().next();
|
||||
|
||||
promise.then(() => $DONE('Promise incorrectly fulfilled.'), ({ constructor }) => {
|
||||
assert.sameValue(iterCount, 0);
|
||||
assert.sameValue(nextCount, 2);
|
||||
assert.sameValue(constructor, TypeError);
|
||||
}).then($DONE, $DONE);
|
||||
|
@ -71,4 +71,4 @@ iter.next().then(() => {
|
||||
assert.sameValue(x, 1, 'x');
|
||||
assert.sameValue(y.length, 0, 'y.length');
|
||||
}).then($DONE, $DONE);
|
||||
}).then($DONE, $DONE);
|
||||
}, $DONE).catch($DONE);
|
||||
|
Loading…
x
Reference in New Issue
Block a user