michael@0: function testLengthInString() michael@0: { michael@0: var s = new String(); michael@0: var res = "length" in s; michael@0: for (var i = 0; i < 5; i++) michael@0: res = res && ("length" in s); michael@0: res = res && s.hasOwnProperty("length"); michael@0: for (var i = 0; i < 5; i++) michael@0: res = res && s.hasOwnProperty("length"); michael@0: return res; michael@0: } michael@0: assertEq(testLengthInString(), true);