summaryrefslogtreecommitdiff
path: root/test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-c-i-4.js
diff options
context:
space:
mode:
Diffstat (limited to 'test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-c-i-4.js')
-rw-r--r--test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-c-i-4.js17
1 files changed, 9 insertions, 8 deletions
diff --git a/test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-c-i-4.js b/test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-c-i-4.js
index a5226d8d8..a5145b80d 100644
--- a/test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-c-i-4.js
+++ b/test/built-ins/Array/prototype/reduceRight/15.4.4.22-9-c-i-4.js
@@ -9,14 +9,15 @@ description: >
property that overrides an inherited data property on an Array
---*/
- var testResult = false;
- function callbackfn(prevVal, curVal, idx, obj) {
- if (idx === 1) {
- testResult = (curVal === 1);
- }
- }
+var testResult = false;
- Array.prototype[1] = "11";
- [0, 1, 2].reduceRight(callbackfn, "initialValue");
+function callbackfn(prevVal, curVal, idx, obj) {
+ if (idx === 1) {
+ testResult = (curVal === 1);
+ }
+}
+
+Array.prototype[1] = "11";
+[0, 1, 2].reduceRight(callbackfn, "initialValue");
assert(testResult, 'testResult !== true');