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

Unified Diff: LayoutTests/inspector/sources/debugger/async-operation-breakpoints.html

Issue 1153923005: DevTools: shard inspector/debugger tests for faster execution. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 7 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: LayoutTests/inspector/sources/debugger/async-operation-breakpoints.html
diff --git a/LayoutTests/inspector/sources/debugger/async-operation-breakpoints.html b/LayoutTests/inspector/sources/debugger/async-operation-breakpoints.html
deleted file mode 100644
index 19c4bd20a29d31d09b09228b95c331b31bdfdf0b..0000000000000000000000000000000000000000
--- a/LayoutTests/inspector/sources/debugger/async-operation-breakpoints.html
+++ /dev/null
@@ -1,114 +0,0 @@
-<html>
-<head>
-<script src="../../../http/tests/inspector/inspector-test.js"></script>
-<script src="../../../http/tests/inspector/debugger-test.js"></script>
-<script src="resources/framework.js"></script>
-<script>
-
-var dummy = function FAIL_should_not_pause_here() { return 0; };
-
-function testFunction()
-{
- debugger;
-
- setTimeout(dummy, 0);
- setTimeout(dummy, 30);
- (function setAsyncBreakpointForMe() { setTimeout(callback1, 20); })();
- setTimeout(dummy, 0);
- Promise.resolve(42)
- .then(dummy);
-
- debugger; // Stop the debugger to receive pending AsyncOperation events.
-}
-
-function callback1()
-{
- var func = setTimeout.bind(null, callback2, 0);
- func = setTimeout.bind(null, func, 0);
- func = setTimeout.bind(null, func, 0);
- (function setAsyncBreakpointForMe() { setTimeout(func); })();
- debugger;
- return 1;
-}
-
-function callback2()
-{
- var func = Framework.willSchedule(callback3);
- func = Framework.willSchedule(func);
- func = Framework.willSchedule(func);
- (function setAsyncBreakpointForMe() { Framework.schedule(func); })();
- debugger;
- Promise.resolve().then(dummy).then(dummy).then(dummy);
- setTimeout(dummy, 0);
- return 2;
-}
-
-function callback3()
-{
- return 3;
-}
-
-function test()
-{
- var maxAsyncCallStackDepth = 4;
- var frameworkRegexString = "/framework\\.js$";
- WebInspector.settingForTest("skipStackFramesPattern").set(frameworkRegexString);
-
- InspectorTest.startDebuggerTest(step1, true);
-
- function step1()
- {
- InspectorTest.runTestFunctionAndWaitUntilPaused(step2);
- }
-
- function step2()
- {
- InspectorTest.debuggerModel.addEventListener(WebInspector.DebuggerModel.Events.AsyncOperationStarted, onAsyncOperationStarted);
- InspectorTest.DebuggerAgent.setAsyncCallStackDepth(maxAsyncCallStackDepth, step3);
- }
-
- function step3()
- {
- var callbackFuncCount = 3;
- iterate();
-
- function iterate()
- {
- if (!callbackFuncCount--) {
- InspectorTest.completeDebuggerTest();
- return;
- }
- InspectorTest.waitUntilPausedAndPerformSteppingActions(["Resume", "Resume"], InspectorTest.waitUntilPaused.bind(InspectorTest, didPause));
- }
-
- function didPause(callFrames, reason, breakpointIds, asyncStackTrace)
- {
- InspectorTest.captureStackTrace(callFrames);
- InspectorTest.addResult("Pause reason: " + reason);
- iterate();
- }
- }
-
- function onAsyncOperationStarted(event)
- {
- var operation = event.data;
- var callFrames = operation.stackTrace || [];
- for (var callFrame of callFrames) {
- var functionName = callFrame && callFrame.functionName;
- if (functionName === "setAsyncBreakpointForMe") {
- InspectorTest.DebuggerAgent.setAsyncOperationBreakpoint(operation.id);
- break;
- }
- }
- }
-}
-
-</script>
-</head>
-
-<body onload="runTest()">
-<p>
-Tests AsyncOperation breakpoints.
-</p>
-</body>
-</html>

Powered by Google App Engine
This is Rietveld 408576698