diff options
Diffstat (limited to 'test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-b-22.js')
-rw-r--r-- | test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-b-22.js | 56 |
1 files changed, 28 insertions, 28 deletions
diff --git a/test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-b-22.js b/test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-b-22.js index 8c57a1bd2..d0bffcff6 100644 --- a/test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-b-22.js +++ b/test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-b-22.js @@ -9,34 +9,34 @@ description: > index property not to be visited on an Array ---*/ -var accessed = false; -var testResult = true; - -function callbackfn(prevVal, curVal, idx, obj) { - accessed = true; - if (idx === 1) { - testResult = false; - } -} - -var arr = [1, 2, 4]; - -Object.defineProperty(arr, "1", { - get: function() { - return "6.99"; - }, - configurable: true -}); - -Object.defineProperty(arr, "2", { - get: function() { - delete arr[1]; - return 0; - }, - configurable: true -}); - -arr.reduceRight(callbackfn, "initialValue"); + var accessed = false; + var testResult = true; + + function callbackfn(prevVal, curVal, idx, obj) { + accessed = true; + if (idx === 1) { + testResult = false; + } + } + + var arr = [1, 2, 4]; + + Object.defineProperty(arr, "1", { + get: function () { + return "6.99"; + }, + configurable: true + }); + + Object.defineProperty(arr, "2", { + get: function () { + delete arr[1]; + return 0; + }, + configurable: true + }); + + arr.reduceRight(callbackfn, "initialValue"); assert(testResult, 'testResult !== true'); assert(accessed, 'accessed !== true'); |