OLD | NEW |
1 # Copyright 2013 the V8 project authors. All rights reserved. | 1 # Copyright 2013 the V8 project authors. All rights reserved. |
2 # Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. | 2 # Copyright (C) 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserved. |
3 # | 3 # |
4 # Redistribution and use in source and binary forms, with or without | 4 # Redistribution and use in source and binary forms, with or without |
5 # modification, are permitted provided that the following conditions | 5 # modification, are permitted provided that the following conditions |
6 # are met: | 6 # are met: |
7 # 1. Redistributions of source code must retain the above copyright | 7 # 1. Redistributions of source code must retain the above copyright |
8 # notice, this list of conditions and the following disclaimer. | 8 # notice, this list of conditions and the following disclaimer. |
9 # 2. Redistributions in binary form must reproduce the above copyright | 9 # 2. Redistributions in binary form must reproduce the above copyright |
10 # notice, this list of conditions and the following disclaimer in the | 10 # notice, this list of conditions and the following disclaimer in the |
(...skipping 124 matching lines...) Loading... |
135 PASS 'use strict'; var o = Object.defineProperty(Object.defineProperty({foo:1},
'foo', {get:function(){return 42;}, set:function(x){this.result = x;}}), 'foo',
{set:function(){this.result = 13;}}); o.foo = 42; o.result; is 13 | 135 PASS 'use strict'; var o = Object.defineProperty(Object.defineProperty({foo:1},
'foo', {get:function(){return 42;}, set:function(x){this.result = x;}}), 'foo',
{set:function(){this.result = 13;}}); o.foo = 42; o.result; is 13 |
136 PASS 'use strict'; var o = Object.defineProperty(Object.defineProperty({foo:1},
'foo', {get:function(){return 42;}, set:function(x){this.result = x;}}), 'foo',
{set:undefined}); o.foo is 42 | 136 PASS 'use strict'; var o = Object.defineProperty(Object.defineProperty({foo:1},
'foo', {get:function(){return 42;}, set:function(x){this.result = x;}}), 'foo',
{set:undefined}); o.foo is 42 |
137 PASS 'use strict'; var o = Object.defineProperty(Object.defineProperty({foo:1},
'foo', {get:function(){return 42;}, set:function(x){this.result = x;}}), 'foo',
{set:undefined}); o.foo = 42; o.result; threw exception TypeError: Cannot set pr
operty foo of #<Object> which has only a getter. | 137 PASS 'use strict'; var o = Object.defineProperty(Object.defineProperty({foo:1},
'foo', {get:function(){return 42;}, set:function(x){this.result = x;}}), 'foo',
{set:undefined}); o.foo = 42; o.result; threw exception TypeError: Cannot set pr
operty foo of #<Object> which has only a getter. |
138 PASS 0 in Object.prototype is true | 138 PASS 0 in Object.prototype is true |
139 PASS '0' in Object.prototype is true | 139 PASS '0' in Object.prototype is true |
140 PASS var o = {}; o.readOnly = false; o.readOnly is true | 140 PASS var o = {}; o.readOnly = false; o.readOnly is true |
141 PASS 'use strict'; var o = {}; o.readOnly = false; o.readOnly threw exception Ty
peError: Cannot assign to read only property 'readOnly' of #<Object>. | 141 PASS 'use strict'; var o = {}; o.readOnly = false; o.readOnly threw exception Ty
peError: Cannot assign to read only property 'readOnly' of #<Object>. |
142 PASS Object.getOwnPropertyDescriptor(Object.defineProperty(Object.defineProperty
({}, 'foo', {get: function() { return false; }, configurable: true}), 'foo', {va
lue:false}), 'foo').writable is false | 142 PASS Object.getOwnPropertyDescriptor(Object.defineProperty(Object.defineProperty
({}, 'foo', {get: function() { return false; }, configurable: true}), 'foo', {va
lue:false}), 'foo').writable is false |
143 PASS Object.getOwnPropertyDescriptor(Object.defineProperty(Object.defineProperty
({}, 'foo', {get: function() { return false; }, configurable: true}), 'foo', {va
lue:false, writable: false}), 'foo').writable is false | 143 PASS Object.getOwnPropertyDescriptor(Object.defineProperty(Object.defineProperty
({}, 'foo', {get: function() { return false; }, configurable: true}), 'foo', {va
lue:false, writable: false}), 'foo').writable is false |
144 PASS Object.getOwnPropertyDescriptor(Object.defineProperty(Object.defineProperty
({}, 'foo', {get: function() { return false; }, configurable: true}), 'foo', {va
lue:false, writable: true}), 'foo').writable is true | 144 PASS Object.getOwnPropertyDescriptor(Object.defineProperty(Object.defineProperty
({}, 'foo', {get: function() { return false; }, configurable: true}), 'foo', {va
lue:false, writable: true}), 'foo').writable is true |
145 FAIL var a = Object.defineProperty([], 'length', {writable: false}); a[0] = 42;
0 in a; should be false. Was true. | 145 PASS var a = Object.defineProperty([], 'length', {writable: false}); a[0] = 42;
0 in a; is false |
146 FAIL 'use strict'; var a = Object.defineProperty([], 'length', {writable: false}
); a[0] = 42; 0 in a; should throw an exception. Was true. | 146 PASS 'use strict'; var a = Object.defineProperty([], 'length', {writable: false}
); a[0] = 42; 0 in a; threw exception TypeError: Cannot assign to read only prop
erty 'length' of [object Array]. |
147 PASS var a = Object.defineProperty([42], '0', {writable: false}); a[0] = false;
a[0]; is 42 | 147 PASS var a = Object.defineProperty([42], '0', {writable: false}); a[0] = false;
a[0]; is 42 |
148 PASS 'use strict'; var a = Object.defineProperty([42], '0', {writable: false});
a[0] = false; a[0]; threw exception TypeError: Cannot assign to read only proper
ty '0' of [object Array]. | 148 PASS 'use strict'; var a = Object.defineProperty([42], '0', {writable: false});
a[0] = false; a[0]; threw exception TypeError: Cannot assign to read only proper
ty '0' of [object Array]. |
149 PASS var a = Object.defineProperty([], '0', {set: undefined}); a[0] = 42; a[0];
is undefined. | 149 PASS var a = Object.defineProperty([], '0', {set: undefined}); a[0] = 42; a[0];
is undefined. |
150 PASS 'use strict'; var a = Object.defineProperty([], '0', {set: undefined}); a[0
] = 42; a[0]; threw exception TypeError: Cannot set property 0 of [object Array]
which has only a getter. | 150 PASS 'use strict'; var a = Object.defineProperty([], '0', {set: undefined}); a[0
] = 42; a[0]; threw exception TypeError: Cannot set property 0 of [object Array]
which has only a getter. |
151 PASS anObj.slot1 is "foo" | 151 PASS anObj.slot1 is "foo" |
152 PASS anObj.slot2 is "bar" | 152 PASS anObj.slot2 is "bar" |
153 PASS anObj.propertyIsEnumerable('slot1') is true | 153 PASS anObj.propertyIsEnumerable('slot1') is true |
154 PASS anObj.propertyIsEnumerable('slot2') is false | 154 PASS anObj.propertyIsEnumerable('slot2') is false |
155 PASS anObj.slot4 is "goo" | 155 PASS anObj.slot4 is "goo" |
156 PASS anObj.slot5 is 123 | 156 PASS anObj.slot5 is 123 |
(...skipping 10 matching lines...) Loading... |
167 PASS anObj.slot5 is 123 | 167 PASS anObj.slot5 is 123 |
168 PASS anObj._Slot5 is 123 | 168 PASS anObj._Slot5 is 123 |
169 PASS Object.getOwnPropertyDescriptor(anObj, 'slot5') is undefined. | 169 PASS Object.getOwnPropertyDescriptor(anObj, 'slot5') is undefined. |
170 PASS anObj.slot5 is 456 | 170 PASS anObj.slot5 is 456 |
171 PASS anObj._Slot5 is 123 | 171 PASS anObj._Slot5 is 123 |
172 PASS Object.getOwnPropertyDescriptor(anObj, 'slot5').value is 456 | 172 PASS Object.getOwnPropertyDescriptor(anObj, 'slot5').value is 456 |
173 PASS successfullyParsed is true | 173 PASS successfullyParsed is true |
174 | 174 |
175 TEST COMPLETE | 175 TEST COMPLETE |
176 | 176 |
OLD | NEW |