mirror of
https://github.com/tc39/test262.git
synced 2025-07-26 15:34:29 +02:00
harness/asyncHelpers.js: Update throwsAsync to not succeed on a bad thenable
Fixes #4186
This commit is contained in:
parent
7a916718cf
commit
feb400c685
@ -72,7 +72,7 @@ assert.throwsAsync = function (expectedErrorConstructor, func, message) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
resolve(res.then(
|
resolve(Promise.resolve(res).then(
|
||||||
function () {
|
function () {
|
||||||
fail(expectation + " but no exception was thrown at all");
|
fail(expectation + " but no exception was thrown at all");
|
||||||
},
|
},
|
||||||
|
Loading…
x
Reference in New Issue
Block a user