Thu, 15 Jan 2015 15:55:04 +0100
Back out 97036ab72558 which inappropriately compared turds to third parties.
michael@0 | 1 | |
michael@0 | 2 | /* Array natives applied to non-arrays. */ |
michael@0 | 3 | |
michael@0 | 4 | var oa = {}; |
michael@0 | 5 | Array.pop(oa); |
michael@0 | 6 | assertEq(oa.length, 0); |
michael@0 | 7 | |
michael@0 | 8 | var ob = {}; |
michael@0 | 9 | Array.push(ob, "twelve"); |
michael@0 | 10 | assertEq(ob.length, 1); |
michael@0 | 11 | |
michael@0 | 12 | var oc = {}; |
michael@0 | 13 | Array.shift(oc); |
michael@0 | 14 | assertEq(oc.length, 0); |
michael@0 | 15 | |
michael@0 | 16 | var od = {}; |
michael@0 | 17 | Array.unshift(od, "eight"); |
michael@0 | 18 | assertEq(od.length, 1); |