tor-browser

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

15.2.3.6-4-55.js (853B)


      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.6-4-55
      6 description: >
      7    Object.defineProperty - 'name' property doesn't exist in 'O', test
      8    [[Enumerable]] of 'name' property of 'Attributes' is set as false
      9    value if absent in accessor descriptor 'desc' (8.12.9 step 4.b.i)
     10 includes: [propertyHelper.js]
     11 ---*/
     12 
     13 var obj = {};
     14 
     15 var setFunc = function(value) {
     16  obj.setVerifyHelpProp = value;
     17 };
     18 var getFunc = function() {
     19  return 10;
     20 };
     21 
     22 Object.defineProperty(obj, "property", {
     23  set: setFunc,
     24  get: getFunc,
     25  configurable: true
     26 });
     27 verifyEqualTo(obj, "property", getFunc());
     28 
     29 verifyWritable(obj, "property", "setVerifyHelpProp");
     30 
     31 verifyProperty(obj, "property", {
     32  enumerable: false,
     33  configurable: true,
     34 });
     35 
     36 reportCompare(0, 0);