diff options
Diffstat (limited to 'test/built-ins/Array/prototype/map/15.4.4.19-8-8.js')
-rw-r--r-- | test/built-ins/Array/prototype/map/15.4.4.19-8-8.js | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/test/built-ins/Array/prototype/map/15.4.4.19-8-8.js b/test/built-ins/Array/prototype/map/15.4.4.19-8-8.js index 6b3d7146d..0a9f95ed4 100644 --- a/test/built-ins/Array/prototype/map/15.4.4.19-8-8.js +++ b/test/built-ins/Array/prototype/map/15.4.4.19-8-8.js @@ -9,15 +9,20 @@ description: > on an Array-like object ---*/ - var accessed = false; - function callbackfn(val, idx, obj) { - accessed = true; - return val > 10; - } +var accessed = false; - var obj = { 0: 11, 1: 12, length: 0 }; +function callbackfn(val, idx, obj) { + accessed = true; + return val > 10; +} - var testResult = Array.prototype.map.call(obj, callbackfn); +var obj = { + 0: 11, + 1: 12, + length: 0 +}; + +var testResult = Array.prototype.map.call(obj, callbackfn); assert.sameValue(testResult.length, 0, 'testResult.length'); assert.sameValue(accessed, false, 'accessed'); |