tor-browser

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

15.2.3.7-6-a-17.js (663B)


      1 // Copyright (c) 2012 Ecma International.  All rights reserved.
      2 // This code is governed by the BSD license found in the LICENSE file.
      3 
      4 /*---
      5 es5id: 15.2.3.7-6-a-17
      6 description: >
      7    Object.defineProperties - 'O' is the Math object which implements
      8    its own [[GetOwnProperty]] method to get 'P' (8.12.9 step 1 )
      9 ---*/
     10 
     11 Object.defineProperty(Math, "prop", {
     12  value: 11,
     13  writable: true,
     14  configurable: true
     15 });
     16 var hasProperty = Math.hasOwnProperty("prop") && Math.prop === 11;
     17 
     18 Object.defineProperties(Math, {
     19  prop: {
     20    value: 12
     21  }
     22 });
     23 
     24 assert(hasProperty, 'hasProperty !== true');
     25 assert.sameValue(Math.prop, 12, 'Math.prop');
     26 
     27 reportCompare(0, 0);