tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

instance-length.js (653B)


      1 // Copyright 2016 Microsoft, Inc. All rights reserved.
      2 // This code is governed by the BSD license found in the LICENSE file.
      3 
      4 /*---
      5 author: Brian Terlson <brian.terlson@microsoft.com>
      6 esid: sec-async-function-instances-length
      7 description: >
      8  Async functions have a length property that is the number of expected
      9  arguments.
     10 includes: [propertyHelper.js]
     11 ---*/
     12 
     13 async function l0() {}
     14 async function l1(a) {}
     15 async function l2(a, b) {}
     16 assert.sameValue(l0.length, 0);
     17 assert.sameValue(l1.length, 1);
     18 assert.sameValue(l2.length, 2)
     19 
     20 verifyProperty(l0, 'length', {
     21  writable: false,
     22  enumerable: false,
     23  configurable: true,
     24 });
     25 
     26 reportCompare(0, 0);