You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The test() function fails when the function it runs returns a value. It then tries to determine if the value is a Promise to suggest using promise_test() instead. To do so, it checks if the returned value has an own property called "then".
This does not work correctly, as then() is defined in Promise.prototype, not Promise itself. Quick way to reproduce:
test(asynct=>{},"my test");
The harness error is "Test named "my test" inappropriately returned a value" rather than "Test named "my test" inappropriately returned a value, consider using promise_test instead".
The text was updated successfully, but these errors were encountered:
The
test()
function fails when the function it runs returns a value. It then tries to determine if the value is a Promise to suggest usingpromise_test()
instead. To do so, it checks if the returned value has an own property called "then".This does not work correctly, as
then()
is defined inPromise.prototype
, notPromise
itself. Quick way to reproduce:The harness error is "Test named "my test" inappropriately returned a value" rather than "Test named "my test" inappropriately returned a value, consider using
promise_test
instead".The text was updated successfully, but these errors were encountered: