Debian Codegraph @

rhino/testsrc/tests/e4x/XMLList/13.5.4.14.js

raw symbols SCIP
1 /* -*- Mode: java; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*-
2 *
3 * This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6
7 gTestfile = '13.5.4.14.js';
8
9 START("13.5.4.14 - XMLList length()");
10
11 TEST(1, true, XMLList.prototype.hasOwnProperty("length"));
12
13 x = <><alpha>one</alpha></>;
14
15 TEST(2, 1, x.length());
16
17 x = <><alpha>one</alpha><bravo>two</bravo></>;
18
19 TEST(2, 2, x.length());
20
21 emps =
22 <employees>
23 <employee>
24 <name>John</name>
25 </employee>
26 <employee>
27 <name>Sue</name>
28 </employee>
29 </employees>
30
31 correct =
32 <employees>
33 <employee>
34 <prefix>Mr.</prefix>
35 <name>John</name>
36 </employee>
37 <employee>
38 <name>Sue</name>
39 </employee>
40 </employees>
41
42 TEST(3,2,emps..name.length());
43
44 END();