Index: third_party/WebKit/LayoutTests/inspector-protocol/worker/exception-from-worker-contains-stack.html |
diff --git a/third_party/WebKit/LayoutTests/inspector-protocol/worker/exception-from-worker-contains-stack.html b/third_party/WebKit/LayoutTests/inspector-protocol/worker/exception-from-worker-contains-stack.html |
deleted file mode 100644 |
index 6d693e44e91820a04052b7921c7e82083a98a9d6..0000000000000000000000000000000000000000 |
--- a/third_party/WebKit/LayoutTests/inspector-protocol/worker/exception-from-worker-contains-stack.html |
+++ /dev/null |
@@ -1,75 +0,0 @@ |
-<html> |
-<head> |
-<script type="text/javascript" src="../../http/tests/inspector-protocol/inspector-protocol-test.js"></script> |
-<script> |
- |
-var worker1; |
-var worker2; |
- |
-function startWorkers() |
-{ |
- worker1 = new Worker("resources/worker-with-throw.js"); |
- worker1.onerror = function(e) { |
- e.preventDefault(); |
- worker1.terminate(); |
- } |
- worker2 = new Worker("resources/worker-with-throw.js"); |
-} |
- |
-function test() |
-{ |
- InspectorTest.sendCommandOrDie("Target.setAutoAttach", {autoAttach: true, waitForDebuggerOnStart: false}, didEnableWorkerDebugging); |
- |
- function didEnableWorkerDebugging(event) |
- { |
- InspectorTest.sendCommandOrDie("Runtime.evaluate", { expression: "startWorkers()" }); |
- } |
- |
- var workerRequestId = 1; |
- function sendCommandToWorker(method, params, workerId) |
- { |
- InspectorTest.sendCommand("Target.sendMessageToTarget", |
- { |
- "targetId": workerId, |
- "message": JSON.stringify({ "method": method, |
- "params": params, |
- "id": workerRequestId++ }) |
- }); |
- } |
- |
- var waitForWorkers = 2; |
- InspectorTest.eventHandler["Target.attachedToTarget"] = function(messageObject) |
- { |
- var workerId = messageObject["params"]["targetInfo"]["targetId"]; |
- InspectorTest.log("Worker created"); |
- sendCommandToWorker("Runtime.enable", {}, workerId); |
- if (!--waitForWorkers) |
- InspectorTest.sendCommandOrDie("Runtime.evaluate", { expression: "worker1.postMessage(239);worker2.postMessage(42);" }); |
- } |
- |
- var workerTerminated = false; |
- var messageReceived = false; |
- InspectorTest.eventHandler["Target.receivedMessageFromTarget"] = function(messageObject) |
- { |
- var message = JSON.parse(messageObject["params"]["message"]); |
- if (message["method"] === "Runtime.exceptionThrown") { |
- var callFrames = message.params.exceptionDetails.stackTrace ? message.params.exceptionDetails.stackTrace.callFrames : []; |
- InspectorTest.log(callFrames.length > 0 ? "Message with stack trace received." : "[FAIL] Message contains empty stack trace"); |
- messageReceived = true; |
- if (messageReceived && workerTerminated) |
- InspectorTest.completeTest(); |
- } |
- } |
- |
- InspectorTest.eventHandler["Target.detachedFromTarget"] = function(messageObject) |
- { |
- InspectorTest.eventHandler["Target.detachedFromTarget"] = undefined; |
- workerTerminated = true; |
- if (messageReceived && workerTerminated) |
- InspectorTest.completeTest(); |
- } |
-} |
-</script> |
-</head> |
-<body onload="runTest()">Tests that console message from worker contains stack trace.</body> |
-</html> |