diff -r 000000000000 -r 6474c204b198 js/src/jit-test/tests/jaeger/testPropCallElem2.js --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/js/src/jit-test/tests/jaeger/testPropCallElem2.js Wed Dec 31 06:09:35 2014 +0100 @@ -0,0 +1,20 @@ +// vim: set ts=8 sts=4 et sw=4 tw=99: + +function testUKeyUObject(a, key1, key2, key3) { + a.a = function () { return this.d; } + a.b = function () { return this.e; } + a.c = function() { return this.f; } + a.d = 20; + a.e = "hi"; + a.f = 500; + delete a["b"]; + Object.defineProperty(a, "b", { get: function () { return function () { return this.e; } } }); + assertEq(a[key1](), 20); + assertEq(a[key2](), "hi"); + assertEq(a[key3](), 500); +} + +for (var i = 0; i < 5; i++) + testUKeyUObject({}, "a", "b", "c"); + +