diff options
author | Rick Waldron <waldron.rick@gmail.com> | 2018-02-09 11:35:37 -0500 |
---|---|---|
committer | Leo Balter <leonardo.balter@gmail.com> | 2018-02-09 11:35:37 -0500 |
commit | a01de4a722d088055a7d84d8c691ddd7109edb34 (patch) | |
tree | f583c8efd40a3b699261f1166da75a9861d83e7b /test/built-ins/Array/prototype/reduce/15.4.4.21-8-b-iii-1-9.js | |
parent | 7b01f9799f99851955f23c18c12e6651c1941022 (diff) | |
download | qtdeclarative-testsuites-a01de4a722d088055a7d84d8c691ddd7109edb34.tar.gz |
js-beautify: make all indentation consistent (depth & character) (#1409)
Diffstat (limited to 'test/built-ins/Array/prototype/reduce/15.4.4.21-8-b-iii-1-9.js')
-rw-r--r-- | test/built-ins/Array/prototype/reduce/15.4.4.21-8-b-iii-1-9.js | 33 |
1 files changed, 19 insertions, 14 deletions
diff --git a/test/built-ins/Array/prototype/reduce/15.4.4.21-8-b-iii-1-9.js b/test/built-ins/Array/prototype/reduce/15.4.4.21-8-b-iii-1-9.js index 82a348b81..d61c61aea 100644 --- a/test/built-ins/Array/prototype/reduce/15.4.4.21-8-b-iii-1-9.js +++ b/test/built-ins/Array/prototype/reduce/15.4.4.21-8-b-iii-1-9.js @@ -9,21 +9,26 @@ description: > property on an Array-like object ---*/ - var testResult = false; - function callbackfn(prevVal, curVal, idx, obj) { - if (idx === 1) { - testResult = (prevVal === 0); - } - } +var testResult = false; - var obj = { 1: 1, 2: 2, length: 3 }; - Object.defineProperty(obj, "0", { - get: function () { - return 0; - }, - configurable: true - }); +function callbackfn(prevVal, curVal, idx, obj) { + if (idx === 1) { + testResult = (prevVal === 0); + } +} - Array.prototype.reduce.call(obj, callbackfn); +var obj = { + 1: 1, + 2: 2, + length: 3 +}; +Object.defineProperty(obj, "0", { + get: function() { + return 0; + }, + configurable: true +}); + +Array.prototype.reduce.call(obj, callbackfn); assert(testResult, 'testResult !== true'); |