| This page tests what happens when a getter / setter on the window object conflicts with another property or declared variable |
| |
| On success, you will see a series of "PASS" messages, followed by "TEST COMPLETE". |
| |
| |
| PASS function () { |
| window.__defineGetter__("x", function() { return "window.x __getter__"; }); |
| } threw exception TypeError: Attempting to change configurable attribute of unconfigurable property.. |
| PASS window.x is 1 |
| PASS typeof window.__lookupGetter__('x') is 'undefined' |
| PASS typeof Object.getOwnPropertyDescriptor(window, 'x').get is 'undefined' |
| |
| PASS function () { |
| window.__defineSetter__("x", function() { debug("window.x __setter__ called"); }); |
| } threw exception TypeError: Attempting to change configurable attribute of unconfigurable property.. |
| PASS window.x is 2 |
| PASS typeof window.__lookupGetter__('x') is 'undefined' |
| PASS typeof Object.getOwnPropertyDescriptor(window, 'x').get is 'undefined' |
| |
| PASS window.y is 'window.y __getter__' |
| PASS typeof window.__lookupGetter__('y') is 'function' |
| PASS typeof Object.getOwnPropertyDescriptor(window, 'y').get is 'function' |
| |
| PASS window.y is 'window.y __getter__' |
| PASS typeof window.__lookupGetter__('y') is 'function' |
| PASS typeof Object.getOwnPropertyDescriptor(window, 'y').get is 'function' |
| |
| PASS window.z is undefined. |
| PASS typeof window.__lookupSetter__('z') is 'function' |
| PASS typeof Object.getOwnPropertyDescriptor(window, 'z').set is 'function' |
| |