Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / inspector / sources / debugger-pause / debugger-eval-on-call-frame-inside-iframe.html
blob0a223e43b2548381891933ded9c147abfd862907
1 <html>
2 <head>
3 <script src="../../../http/tests/inspector/inspector-test.js"></script>
4 <script src="../../../http/tests/inspector/console-test.js"></script>
5 <script src="../../../http/tests/inspector/debugger-test.js"></script>
6 <script>
8 function dirxml() { return "overridden dirxml() in top frame"; }
10 function onload()
12 var iframe = document.getElementById("iframe");
13 var doc = iframe.contentWindow.document;
15 var html = "<html><head><script>\n" +
16 "function dir() { return 'overridden dir() in iframe'; }\n" +
17 "function pauseInsideIframe()\n" +
18 "{\n" +
19 " var table = 'local in iframe';\n" +
20 " debugger;\n" +
21 "}\n" +
22 "</" + "script></" + "head><" + "body></" + "body></" + "html>";
23 doc.open();
24 doc.write(html);
25 doc.close();
27 runTest();
30 function testFunction()
32 var clear = "local in top frame";
33 var iframe = document.getElementById("iframe");
34 iframe.contentWindow.pauseInsideIframe.call({foo: 42});
37 var test = function()
39 var expressions = [
40 "dir()",
41 "dirxml()",
42 "table",
43 "clear",
44 "x:", // print correct syntax error: crbug.com/110163
47 function evaluateInConsoleAndDump(callback)
49 var copy = expressions.slice();
50 inner();
52 function inner()
54 var expression = copy.shift();
55 if (expression)
56 InspectorTest.evaluateInConsoleAndDump(expression, inner);
57 else
58 callback();
62 InspectorTest.startDebuggerTest(step1, true);
64 function step1()
66 InspectorTest.runTestFunctionAndWaitUntilPaused(step2);
69 function step2(callFrames)
71 InspectorTest.captureStackTrace(callFrames);
72 InspectorTest.addResult("\n=== Evaluating on iframe ===");
73 evaluateInConsoleAndDump(step3);
76 function step3()
78 var pane = WebInspector.panels.sources.sidebarPanes.callstack;
79 pane._callFrameSelected(pane.callFrames[1]);
80 InspectorTest.runAfterPendingDispatches(step4);
83 function step4()
85 InspectorTest.addResult("\n=== Evaluating on top frame ===");
86 evaluateInConsoleAndDump(step5);
89 function step5()
91 InspectorTest.completeDebuggerTest();
95 </script>
96 </head>
98 <body onload="onload()">
99 <iframe id="iframe"></iframe>
101 Test that evaluation on call frame works across all inspected windows in the call stack.
102 </p>
104 </body>
105 </html>