michael@0: /* michael@0: * Call the trap with the handler as the this value, and the target as the first michael@0: * argument michael@0: */ michael@0: var target = {}; michael@0: var called = false; michael@0: var handler = { michael@0: keys: function (target1) { michael@0: assertEq(this, handler); michael@0: assertEq(target1, target); michael@0: called = true; michael@0: return []; michael@0: } michael@0: }; michael@0: Object.keys(new Proxy(target, handler)); michael@0: assertEq(called, true);