summaryrefslogtreecommitdiffstats
path: root/js/src/tests/ecma_6/Promise/bug-1289040.js
blob: 9290d8ad46fa4de1303fec365caa08b63d39d91d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
if (!this.Promise) {
    this.reportCompare && reportCompare(true,true);
    quit(0);
}

var global = newGlobal();
Promise.prototype.then = global.Promise.prototype.then;
p1 = new Promise(function f(r) {
    r(1);
});
p2 = p1.then(function g(){});

this.reportCompare && reportCompare(true,true);