(length)
| 152 | |
| 153 | |
| 154 | function TestNonArrayLongerLength(length) { |
| 155 | var x = {}; |
| 156 | x[0] = 42; |
| 157 | x[2] = 37; |
| 158 | x.length = length; |
| 159 | Array.prototype.sort.call(x); |
| 160 | assertEquals(length, x.length, "longlength length"); |
| 161 | assertEquals(37, x[0], "longlength first"); |
| 162 | assertEquals(42, x[1], "longlength second"); |
| 163 | assertFalse(2 in x,"longlength third"); |
| 164 | } |
| 165 | |
| 166 | TestNonArrayLongerLength(4); |
| 167 | TestNonArrayLongerLength(10); |
no test coverage detected
searching dependent graphs…