js/src/tests/ecma_2/instanceof/instanceof-002.js

branch
TOR_BUG_3246
changeset 7
129ffea94266
equal deleted inserted replaced
-1:000000000000 0:48ee60f889f3
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
5
6
7 /**
8 File Name:
9 ECMA Section:
10 Description: Call Objects
11
12
13
14 Author: christine@netscape.com
15 Date: 12 november 1997
16 */
17 var SECTION = "";
18 var VERSION = "ECMA_2";
19 var TITLE = "The Call Constructor";
20
21 startTest();
22 writeHeaderToLog( SECTION + " "+ TITLE);
23
24 var b = new Boolean();
25
26 new TestCase( SECTION,
27 "var b = new Boolean(); b instanceof Boolean",
28 true,
29 b instanceof Boolean );
30
31 new TestCase( SECTION,
32 "b instanceof Object",
33 true,
34 b instanceof Object );
35
36 new TestCase( SECTION,
37 "b instanceof Array",
38 false,
39 b instanceof Array );
40
41 new TestCase( SECTION,
42 "true instanceof Boolean",
43 false,
44 true instanceof Boolean );
45
46 new TestCase( SECTION,
47 "Boolean instanceof Object",
48 true,
49 Boolean instanceof Object );
50 test();
51

mercurial