diff --git a/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A10.js b/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A10.js deleted file mode 100644 index 67b8c7ae86..0000000000 --- a/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A10.js +++ /dev/null @@ -1,29 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: | - The Object.prototype.hasOwnProperty.length property has the attribute - ReadOnly -es5id: 15.2.4.5_A10 -description: > - Checking if varying the Object.prototype.hasOwnProperty.length - property fails -includes: [propertyHelper.js] ----*/ - -//CHECK#1 -if (!(Object.prototype.hasOwnProperty.hasOwnProperty('length'))) { - $ERROR('#1: the Object.prototype.hasOwnProperty has length property.'); -} - -var obj = Object.prototype.hasOwnProperty.length; - -verifyNotWritable(Object.prototype.hasOwnProperty, "length", null, function() { - return "shifted"; -}); - -//CHECK#2 -if (Object.prototype.hasOwnProperty.length !== obj) { - $ERROR('#2: the Object.prototype.hasOwnProperty length property has the attributes ReadOnly.'); -} diff --git a/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A11.js b/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A11.js deleted file mode 100644 index 5cc9e47507..0000000000 --- a/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A11.js +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: The length property of the hasOwnProperty method is 1 -es5id: 15.2.4.5_A11 -description: Checking the Object.prototype.hasOwnProperty.length ----*/ - -//CHECK#1 -if (!(Object.prototype.hasOwnProperty.hasOwnProperty("length"))) { - $ERROR('#1: The length property of the toObject method is 1'); -} - -//CHECK#2 -if (Object.prototype.hasOwnProperty.length !== 1) { - $ERROR('#2: The length property of the toObject method is 1'); -} diff --git a/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A8.js b/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A8.js deleted file mode 100644 index 78e7282692..0000000000 --- a/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A8.js +++ /dev/null @@ -1,30 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: | - The Object.prototype.hasOwnProperty.length property has the attribute - DontEnum -es5id: 15.2.4.5_A8 -description: > - Checking if enumerating the Object.prototype.hasOwnProperty.length - property fails ----*/ - -//CHECK#0 -if (!(Object.prototype.hasOwnProperty.hasOwnProperty('length'))) { - $ERROR('#0: the Object.prototype.hasOwnProperty has length property.'); -} - - -// CHECK#1 -if (Object.prototype.hasOwnProperty.propertyIsEnumerable('length')) { - $ERROR('#1: the Object.prototype.hasOwnProperty.length property has the attributes DontEnum'); -} - -// CHECK#2 -for (var p in Object.prototype.hasOwnProperty) { - if (p === "length") - $ERROR('#2: the Object.prototype.hasOwnProperty.length property has the attributes DontEnum'); -} -// diff --git a/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A9.js b/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A9.js deleted file mode 100644 index ad38ceb598..0000000000 --- a/test/built-ins/Object/prototype/hasOwnProperty/S15.2.4.5_A9.js +++ /dev/null @@ -1,27 +0,0 @@ -// Copyright 2009 the Sputnik authors. All rights reserved. -// This code is governed by the BSD license found in the LICENSE file. - -/*--- -info: | - The Object.prototype.hasOwnProperty.length property does not have the - attribute DontDelete -es5id: 15.2.4.5_A9 -description: > - Checking if deleting the Object.prototype.hasOwnProperty.length - property fails ----*/ - -//CHECK#0 -if (!(Object.prototype.hasOwnProperty.hasOwnProperty('length'))) { - $ERROR('#0: the Object.prototype.hasOwnProperty has length property'); -} - -//CHECK#1 -if (!delete Object.prototype.hasOwnProperty.length) { - $ERROR('#1: The Object.prototype.hasOwnProperty.length property does not have the attributes DontDelete'); -} - -//CHECK#2 -if (Object.prototype.hasOwnProperty.hasOwnProperty('length')) { - $ERROR('#2: The Object.prototype.hasOwnProperty.length property does not have the attributes DontDelete'); -} diff --git a/test/built-ins/Object/prototype/hasOwnProperty/length.js b/test/built-ins/Object/prototype/hasOwnProperty/length.js new file mode 100644 index 0000000000..6430d94f4a --- /dev/null +++ b/test/built-ins/Object/prototype/hasOwnProperty/length.js @@ -0,0 +1,28 @@ +// Copyright (C) 2009 the Sputnik authors. All rights reserved. +// This code is governed by the BSD license found in the LICENSE file. +/*--- +esid: sec-object.prototype.hasownproperty +description: > + Object.prototype.hasOwnProperty.length is 1. +info: | + Object.prototype.hasOwnProperty ( V ) + + ECMAScript Standard Built-in Objects + + Every built-in function object, including constructors, has a "length" + property whose value is an integer. Unless otherwise specified, this + value is equal to the largest number of named arguments shown in the + subclause headings for the function description. + + Unless otherwise specified, the "length" property of a built-in Function + object has the attributes { [[Writable]]: false, [[Enumerable]]: false, + [[Configurable]]: true }. +includes: [propertyHelper.js] +---*/ + +verifyProperty(Object.prototype.hasOwnProperty, "length", { + value: 1, + writable: false, + enumerable: false, + configurable: true, +});