Release assert with <img usemap> in shadow tree
[WebKit-https.git] / JSTests / es6 / generators_%GeneratorPrototype%.js
1 function test() {
2
3 function * generatorFn(){}
4 var ownProto = Object.getPrototypeOf(generatorFn());
5 var passed = ownProto === generatorFn.prototype;
6
7 var sharedProto = Object.getPrototypeOf(ownProto);
8 passed &= sharedProto !== Object.prototype &&
9   sharedProto === Object.getPrototypeOf(function*(){}.prototype) &&
10   sharedProto.hasOwnProperty('next');
11
12 return passed;
13       
14 }
15
16 if (!test())
17     throw new Error("Test failed");
18