aboutsummaryrefslogtreecommitdiffstats
path: root/website/resources/scripts/testcases2/15.2.3_Properties_of_the_Object_Constructor.json
blob: 2d6519f076dfedb201bb4caafe4ee7ff0b949df9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
{
 "testCollection": {
  "name": "15.2.3_Properties_of_the_Object_Constructor",
  "numTests": 3,
  "tests": [
   {
    "section": "15.2.3",
    "description": "Checking existence of the property \"prototype\"",
    "test": "if(!Object.hasOwnProperty(\"prototype\")){\n  $ERROR('#1: The Object constructor has the property \"prototype\"');\n}\n",
    "id": "S15.2.3_A1"
   },
   {
    "section": "15.2.3, 15.2.4",
    "description": "Checking Function.prototype.isPrototypeOf(Object)",
    "test": "// CHECK#\nif (!(Function.prototype.isPrototypeOf(Object))) {\n  $ERROR('#1: the value of the internal [[Prototype]] property of the Object constructor is the Function prototype object.');\n}\n",
    "id": "S15.2.3_A2"
   },
   {
    "section": "15.2.3, 15.2.4",
    "description": "Checking Object.length",
    "test": "//CHECK#1\nif(!Object.hasOwnProperty(\"length\")){\n  $ERROR('#1: The Object constructor has the property \"length\"');\n}\n\n//CHECK#2\nif (Object.length !== 1) {\n  $ERROR('#2: Object.length property value should be 1');\n}\n",
    "id": "S15.2.3_A3"
   }
  ]
 }
}