Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(47)

Unified Diff: third_party/WebKit/LayoutTests/inspector-protocol/debugger/debugger-pause-in-tight-loop.html

Issue 2968523003: [DevTools] Migrate inspector-protocol/debugger tests to new harness (Closed)
Patch Set: all tests Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/LayoutTests/inspector-protocol/debugger/debugger-pause-in-tight-loop.html
diff --git a/third_party/WebKit/LayoutTests/inspector-protocol/debugger/debugger-pause-in-tight-loop.html b/third_party/WebKit/LayoutTests/inspector-protocol/debugger/debugger-pause-in-tight-loop.html
deleted file mode 100644
index fac7b51719c979c535cdf2f92fdd8272249cc6c8..0000000000000000000000000000000000000000
--- a/third_party/WebKit/LayoutTests/inspector-protocol/debugger/debugger-pause-in-tight-loop.html
+++ /dev/null
@@ -1,62 +0,0 @@
-<html>
-<head>
-<script type="text/javascript" src="../../http/tests/inspector-protocol/resources/inspector-protocol-test.js"></script>
-<script>
-
-function testFunction()
-{
- setTimeout(hotFunction, 0);
-}
-
-var terminated = false;
-function hotFunction() {
- evaluateInFrontend("InspectorTest.didFireTimer()");
-
- var message_id = 1;
- var ts = Date.now();
- while (!terminated) {
- // Without this try/catch v8 will optimize the function and break will not work.
- try {
- if (Date.now() - ts > 1000) {
- ts = Date.now();
- console.error("Message #" + message_id++);
- }
- } catch (e) {
- }
- }
-}
-
-function test()
-{
- InspectorTest.sendCommand("Inspector.enable", {});
- InspectorTest.sendCommand("Debugger.enable", {}, didEnableDebugger);
- function didEnableDebugger()
- {
- // Start tight loop in page.
- InspectorTest.sendCommand("Runtime.evaluate", { "expression": "testFunction()" }, didEval);
- function didEval()
- {
- InspectorTest.log("didEval");
- }
- }
-
- InspectorTest.didFireTimer = function()
- {
- InspectorTest.log("didFireTimer");
- InspectorTest.sendCommand("Debugger.pause", { });
- }
-
- InspectorTest.eventHandler["Debugger.paused"] = function(messageObject)
- {
- var message = messageObject["params"]["message"];
- InspectorTest.log("SUCCESS: Paused");
- InspectorTest.sendCommand("Runtime.evaluate", { "expression": "terminated = true;" });
- InspectorTest.sendCommand("Debugger.resume", { });
- InspectorTest.completeTest();
- }
-}
-</script>
-</head>
-<body onLoad="runTest();">
-</body>
-</html>

Powered by Google App Engine
This is Rietveld 408576698