Simple async test (v3)

Revision 3 of this benchmark created on


Description

Just tick the async checkbox for each asynchronous test. You will then have access to a deferred object. In your test code, whenever your test is finished, call deferred.resolve().

Test runner

Ready to run.

Testing in
TestOps/sec
await Promise
const foo = new Promise(resolve => setTimeout(resolve, 0));

(async function bar() {
	await foo;
	deferred.resolve();
})()
ready
async timeout
setTimeout(function() {
  deferred.resolve();
}, 0);
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.