|
1 // Copyright 2009 the Sputnik authors. All rights reserved. |
|
2 // This code is governed by the BSD license found in the LICENSE file. |
|
3 |
|
4 /** |
|
5 * The PropertyName is undefined, ToString(BooleanLiteral), ToString(nullLiteral) |
|
6 * |
|
7 * @path ch11/11.1/11.1.5/S11.1.5_A4.3.js |
|
8 * @description Creating properties with following names: undefined, 'true', 'null' |
|
9 */ |
|
10 |
|
11 //CHECK#1 |
|
12 var object = {undefined : true}; |
|
13 if (object.undefined !== true) { |
|
14 $ERROR('#1: var object = {undefined : true}; object.undefined === true'); |
|
15 } |
|
16 |
|
17 //CHECK#2 |
|
18 var object = {undefined : true}; |
|
19 if (object["undefined"] !== true) { |
|
20 $ERROR('#2: var object = {undefined : true}; object["undefined"] === true'); |
|
21 } |
|
22 |
|
23 //CHECK#3 |
|
24 var object = {"true" : true}; |
|
25 if (object["true"] !== true) { |
|
26 $ERROR('#3: var object = {"true" : true}; object["true"] === true'); |
|
27 } |
|
28 |
|
29 //CHECK#4 |
|
30 var object = {"null" : true}; |
|
31 if (object["null"] !== true) { |
|
32 $ERROR('#4: var object = {"null" : true}; object["null"] === true'); |
|
33 } |
|
34 |