// Copyright (C) 2020 Rick Waldron. All rights reserved. // This code is governed by the BSD license found in the LICENSE file. /*--- esid: sec-async-arrow-function-definitions desc: > Async function returns an async function. templates: - evaluation/async-class-*.template - evaluation/async-declaration.template - evaluation/async-expression-*.template - evaluation/async-obj-method.template flags: [async] ---*/ //- setup let count = 0; //- params x //- body let a = arguments; return async () => a === arguments; //- teardown asyncFn().then(retFn => { count++; return retFn(); }).then(result => { assert.sameValue(result, true); assert.sameValue(count, 1); }).then($DONE, $DONE);