Merge Chromium + Blink git repositories
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / inspector / sources / debugger / debug-inlined-scripts-fragment-id.html
blob96a380cee39b61628a77315e69dd31aaab573ce2
1 <html>
2 <head>
3 <script>
4 function f4()
6 return 0;
8 f4();
9 </script>
11 <script src="../../../http/tests/inspector/inspector-test.js"></script>
12 <script src="../../../http/tests/inspector/debugger-test.js"></script>
14 <script>
16 var test = function()
18 InspectorTest.startDebuggerTest(step0, true);
20 function step0()
22 InspectorTest.evaluateInPage("window.location=\"#hash\"", step1);
25 function step1(loc)
27 InspectorTest.addResult("window.location: " + loc.description);
28 InspectorTest.showScriptSource("debug-inlined-scripts-fragment-id.html", step2);
31 function step2(sourceFrame)
33 InspectorTest.addResult("Script source was shown.");
34 InspectorTest.setBreakpoint(sourceFrame, 5, "", true);
35 InspectorTest.waitUntilPaused(step3);
36 InspectorTest.reloadPage(InspectorTest.completeDebuggerTest.bind(InspectorTest));
39 function step3(callFrames)
41 InspectorTest.addResult("Script execution paused.");
42 InspectorTest.captureStackTrace(callFrames);
43 InspectorTest.showScriptSource("debug-inlined-scripts-fragment-id.html", step4);
46 function step4(sourceFrame)
48 InspectorTest.dumpSourceFrameContents(sourceFrame);
49 InspectorTest.resumeExecution(InspectorTest.waitUntilPaused.bind(null, step5));
52 function step5(callFrames)
54 if (callFrames[0].location.lineNumber !== 9) {
55 InspectorTest.resumeExecution(InspectorTest.waitUntilPaused.bind(null, step5));
56 return;
58 InspectorTest.addResult("Script execution paused.");
59 InspectorTest.captureStackTrace(callFrames);
60 InspectorTest.showScriptSource("debug-inlined-scripts-fragment-id.html", step6);
63 function step6(sourceFrame)
65 InspectorTest.dumpSourceFrameContents(sourceFrame);
66 InspectorTest.resumeExecution(InspectorTest.waitUntilPaused.bind(null, step7));
69 function step7()
71 InspectorTest.resumeExecution(InspectorTest.waitUntilPaused.bind(null, step5));
75 </script>
77 </head>
79 <body onload="runTest()">
80 <p>
81 Tests that all inlined scripts from the same document are shown in the same source frame with html script tags.
82 <a id="hash" href="https://bugs.webkit.org/show_bug.cgi?id=54544">Bug 54544.</a>
83 </p>
85 </body>
86 </html>