tor-browser

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

builtin.js (1302B)


      1 // |reftest| skip-if(!this.hasOwnProperty('Temporal')) -- Temporal is not enabled unconditionally
      2 // Copyright (C) 2021 Igalia, S.L. All rights reserved.
      3 // This code is governed by the BSD license found in the LICENSE file.
      4 
      5 /*---
      6 esid: sec-temporal.zoneddatetime
      7 description: Tests that Temporal.ZonedDateTime meets the requirements for built-in objects
      8 info: |
      9    Unless specified otherwise, a built-in object that is callable as a function is a built-in
     10    function object with the characteristics described in 10.3. Unless specified otherwise, the
     11    [[Extensible]] internal slot of a built-in object initially has the value true.
     12 
     13    Unless otherwise specified every built-in function and every built-in constructor has the
     14    Function prototype object [...] as the value of its [[Prototype]] internal slot.
     15 features: [Temporal]
     16 ---*/
     17 
     18 assert.sameValue(Object.isExtensible(Temporal.ZonedDateTime),
     19  true, "Built-in objects must be extensible.");
     20 
     21 assert.sameValue(Object.prototype.toString.call(Temporal.ZonedDateTime),
     22  "[object Function]", "Object.prototype.toString");
     23 
     24 assert.sameValue(Object.getPrototypeOf(Temporal.ZonedDateTime),
     25  Function.prototype, "prototype");
     26 
     27 assert.sameValue(typeof Temporal.ZonedDateTime.prototype,
     28  "object", "prototype property");
     29 
     30 reportCompare(0, 0);