haikuwebkit/LayoutTests/fetch/fetch-worker-crash.html

32 lines
800 B
HTML
Raw Permalink Normal View History

ASSERTION FAILED: promise.inherits(JSPromise::info()) https://bugs.webkit.org/show_bug.cgi?id=161632 <rdar://problem/28184743> Patch by Youenn Fablet <youenn@apple.com> on 2016-09-09 Reviewed by Mark Lam. Source/JavaScriptCore: * runtime/JSPromiseDeferred.cpp: (JSC::JSPromiseDeferred::create): Returning null if promise object is not created. Source/WebCore: Test: fetch/fetch-worker-crash.html * bindings/js/JSDOMPromise.h: (WebCore::callPromiseFunction): Returning early if created promise is null. Passing directly a DeferredWrapper to the generated code. * bindings/scripts/CodeGeneratorJS.pm: Updated to take a DeferredWrapper. (GenerateImplementation): (GenerateReturnParameters): * bindings/scripts/test/JS/JSTestObj.cpp: Rebasing expectations. (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionPromise): (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithFloatArgumentPromise): (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithExceptionPromise): (WebCore::jsTestObjPrototypeFunctionTestPromiseFunctionWithOptionalIntArgumentPromise): (WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction1Promise): (WebCore::jsTestObjPrototypeFunctionTestPromiseOverloadedFunction2Promise): (WebCore::jsTestObjConstructorFunctionTestStaticPromiseFunctionPromise): (WebCore::jsTestObjConstructorFunctionTestStaticPromiseFunctionWithExceptionPromise): LayoutTests: * TestExpectations: Reenabling skipped tests. * fetch/fetch-worker-crash-expected.txt: Added. * fetch/fetch-worker-crash.html: Added. * fetch/fetch-worker-crash.js: Added. Canonical link: https://commits.webkit.org/179958@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@205729 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-09-09 09:47:55 +00:00
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>Fetch in worker: ensuring that no crash happens</title>
</head>
<body>
<p id="log">PASS if no crash... </p>
<script>
if (window.testRunner) {
testRunner.dumpAsText();
testRunner.waitUntilDone();
}
var numTerminated = 0;
var numWorker = 50;
for (var cptr = 0; cptr < numWorker; ++cptr) {
let worker = new Worker('fetch-worker-crash.js');
worker.onmessage = (event) => {
if (event.data == "starting")
worker.terminate();
if (++numTerminated == numWorker) {
document.getElementById('log').innerHTML += "DONE";
if (window.testRunner)
testRunner.notifyDone();
}
}
}
</script>
</body>
</html>