Leo Balter d1261bb49d Update files for the curation process
Remove more stress tests with existing coverage or out of context for test262
2018-09-11 18:20:20 -04:00

15 lines
388 B
JavaScript

// Reviewed
function shouldBe(actual, expected) {
if (actual !== expected)
throw new Error('bad value: ' + actual);
}
class DerivedPromise extends Promise {
static get [Symbol.species]() {
return Promise;
}
}
shouldBe(DerivedPromise.all([ 1, 2, 3]) instanceof DerivedPromise, true);
shouldBe(DerivedPromise.race([ 1, 2, 3]) instanceof DerivedPromise, true);