Home | History | Annotate | Download | only in webkit

Lines Matching full:shouldbe

48 shouldBe("[0,1,2,3].reduce(function(a,b){ return a + b; })", "6");
49 shouldBe("[1,2,3].reduce(function(a,b){ return a + b; })", "6");
50 shouldBe("[0,1,2,3].reduce(function(a,b){ return a + b; }, 4)", "10");
51 shouldBe("[1,2,3].reduce(function(a,b){ return a + b; }, 4)", "10");
52 shouldBe("toObject([0,1,2,3]).reduce(function(a,b){ return a + b; })", "6");
53 shouldBe("toObject([1,2,3]).reduce(function(a,b){ return a + b; })", "6");
54 shouldBe("toObject([0,1,2,3]).reduce(function(a,b){ return a + b; }, 4)", "10");
55 shouldBe("toObject([1,2,3]).reduce(function(a,b){ return a + b; }, 4)", "10");
56 shouldBe("toUnorderedObject([0,1,2,3]).reduce(function(a,b){ return a + b; })", "6");
57 shouldBe("toUnorderedObject([1,2,3]).reduce(function(a,b){ return a + b; })", "6");
58 shouldBe("toUnorderedObject([0,1,2,3]).reduce(function(a,b){ return a + b; }, 4)", "10");
59 shouldBe("toUnorderedObject([1,2,3]).reduce(function(a,b){ return a + b; }, 4)", "10");
62 shouldBe("sparseArray.reduce(function(a,b){ return a + b; }, 0)", "10");
63 shouldBe("toObject(sparseArray).reduce(function(a,b){ return a + b; }, 0)", "10");
65 shouldBe("sparseArray.reduce(function(a,b){ callCount++; }); callCount", "0");
67 shouldBe("toObject(sparseArray).reduce(function(a,b){ callCount++; }); callCount", "0");
69 shouldBe("sparseArray.reduce(function(a,b){ callCount++; }, 0); callCount", "1");
71 shouldBe("toObject(sparseArray).reduce(function(a,b){ callCount++; }, 0); callCount", "1");
73 shouldBe("[0,1,2,3,4].reduce(function(a,b){ callCount++; }, 0); callCount", "5");
75 shouldBe("[0,1,2,3,4].reduce(function(a,b){ callCount++; }); callCount", "4");
77 shouldBe("[1, 2, 3, 4].reduce(function(a,b, i, thisObj){ thisObj.length--; callCount++; return a + b; }, 0); callCount", "2");
79 shouldBe("[1, 2, 3, 4].reduce(function(a,b, i, thisObj){ thisObj.length++; callCount++; return a + b; }, 0); callCount", "4");
81 shouldBe("toObject([1, 2, 3, 4]).reduce(function(a,b, i, thisObj){ thisObj.length--; callCount++; return a + b; }, 0); callCount", "4");
83 shouldBe("toObject([1, 2, 3, 4]).reduce(function(a,b, i, thisObj){ thisObj.length++; callCount++; return a + b; }, 0); callCount", "4");
85 shouldBe("[[0,1], [2,3], [4,5]].reduce(function(a,b) {return a.concat(b);}, [])", "[0,1,2,3,4,5]");
86 shouldBe("toObject([[0,1], [2,3], [4,5]]).reduce(function(a,b) {return a.concat(b);}, [])", "[0,1,2,3,4,5]");
87 shouldBe("toObject([0,1,2,3,4,5]).reduce(function(a,b,i) {return a.concat([i,b]);}, [])", "[0,0,1,1,2,2,3,3,4,4,5,5]");
88 shouldBe("toUnorderedObject([[0,1], [2,3], [4,5]]).reduce(function(a,b) {return a.concat(b);}, [])", "[0,1,2,3,4,5]");
89 shouldBe("toUnorderedObject([0,1,2,3,4,5]).reduce(function(a,b,i) {return a.concat([i,b]);}, [])", "[0,0,1,1,2,2,3,3,4,4,5,5]");
90 shouldBe("[0,1,2,3,4,5].reduce(function(a,b,i) {return a.concat([i,b]);}, [])", "[0,0,1,1,2,2,3,3,4,4,5,5]");
91 shouldBe("[2,3].reduce(function() {'use strict'; return this;})", "undefined");