diff -r 000000000000 -r 6474c204b198 js/src/tests/ecma_5/Object/15.2.3.4-01.js --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/js/src/tests/ecma_5/Object/15.2.3.4-01.js Wed Dec 31 06:09:35 2014 +0100 @@ -0,0 +1,30 @@ +/* + * Any copyright is dedicated to the Public Domain. + * http://creativecommons.org/licenses/publicdomain/ + * Contributor: + * Jeff Walden + */ + +//----------------------------------------------------------------------------- +var BUGNUMBER = 518663; +var summary = + 'Object.getOwnPropertyNames should play nicely with enumerator caching'; + +print(BUGNUMBER + ": " + summary); + +/************** + * BEGIN TEST * + **************/ + +for (var p in JSON); +var names = Object.getOwnPropertyNames(JSON); +assertEq(names.length >= 2, true, + "wrong number of property names? [" + names + "]"); +assertEq(names.indexOf("parse") >= 0, true); +assertEq(names.indexOf("stringify") >= 0, true); + +/******************************************************************************/ + +reportCompare(true, true); + +print("All tests passed!");