summaryrefslogtreecommitdiffstats
path: root/js/src/jit-test/tests/proxy/testDirectProxyPreventExtensions1.js
blob: 384be1cf57cc425550df77cc5369898c3f652fb2 (plain)
1
2
3
4
5
6
7
8
9
10
// Forward to the target if the trap is not defined
var target = {};
var proxy = new Proxy(target, {});
Object.preventExtensions(proxy);
assertEq(Object.isExtensible(target), false);

target = {};
proxy = Proxy.revocable(target, {}).proxy;
Object.preventExtensions(proxy);
assertEq(Object.isExtensible(target), false);