| 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 |
info: | |
| 6 |
The PropertyName is undefined, ToString(BooleanLiteral), |
| 7 |
ToString(nullLiteral) |
| 8 |
es5id: 11.1.5_A4.3 |
| 9 |
description: "Creating properties with following names: undefined, 'true', 'null'" |
| 10 |
---*/ |
| 11 |
|
| 12 |
//CHECK#1 |
| 13 |
var object = {undefined : true}; |
| 14 |
if (object.undefined !== true) { |
| 15 |
$ERROR('#1: var object = {undefined : true}; object.undefined === true'); |
| 16 |
} |
| 17 |
|
| 18 |
//CHECK#2 |
| 19 |
var object = {undefined : true}; |
| 20 |
if (object["undefined"] !== true) { |
| 21 |
$ERROR('#2: var object = {undefined : true}; object["undefined"] === true'); |
| 22 |
} |
| 23 |
|
| 24 |
//CHECK#3 |
| 25 |
var object = {"true" : true}; |
| 26 |
if (object["true"] !== true) { |
| 27 |
$ERROR('#3: var object = {"true" : true}; object["true"] === true'); |
| 28 |
} |
| 29 |
|
| 30 |
//CHECK#4 |
| 31 |
var object = {"null" : true}; |
| 32 |
if (object["null"] !== true) { |
| 33 |
$ERROR('#4: var object = {"null" : true}; object["null"] === true'); |
| 34 |
} |