tor-browser

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

15.2.3.6-3-124.js (702B)


      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-3-124
      6 description: >
      7    Object.defineProperty - 'configurable' property in 'Attributes' is
      8    treated as true when it is a string (value is 'false')  (8.10.5
      9    step 4.b)
     10 ---*/
     11 
     12 var obj = {};
     13 
     14 var attr = {
     15  configurable: "false"
     16 };
     17 
     18 Object.defineProperty(obj, "property", attr);
     19 
     20 var beforeDeleted = obj.hasOwnProperty("property");
     21 
     22 delete obj.property;
     23 
     24 var afterDeleted = obj.hasOwnProperty("property");
     25 
     26 assert.sameValue(beforeDeleted, true, 'beforeDeleted');
     27 assert.sameValue(afterDeleted, false, 'afterDeleted');
     28 
     29 reportCompare(0, 0);