1
0
Fork 0
firefox/js/xpconnect/tests/unit/test_bug845862.js
Daniel Baumann 5e9a113729
Adding upstream version 140.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
2025-06-25 09:37:52 +02:00

7 lines
371 B
JavaScript

function run_test() {
var sb = new Cu.Sandbox('http://www.example.com');
Cu.evalInSandbox("this.foo = {}; Object.defineProperty(foo, 'bar', {get: function() {return {};}});", sb);
var desc = Object.getOwnPropertyDescriptor(Cu.waiveXrays(sb.foo), 'bar');
var b = desc.get();
Assert.ok(b != XPCNativeWrapper(b), "results from accessor descriptors are waived");
}