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

Side by Side Diff: third_party/WebKit/LayoutTests/inspector/elements/elements-inspect-iframe-from-different-domain.html

Issue 1877223003: DevTools: deprecate InspectorTest.runAfterPendingDispatches (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 unified diff | Download patch
OLDNEW
1 <html> 1 <html>
2 <head> 2 <head>
3 <script src="../../http/tests/inspector/inspector-test.js"></script> 3 <script src="../../http/tests/inspector/inspector-test.js"></script>
4 <script src="../../http/tests/inspector/console-test.js"></script> 4 <script src="../../http/tests/inspector/console-test.js"></script>
5 <script src="../../http/tests/inspector/elements-test.js"></script> 5 <script src="../../http/tests/inspector/elements-test.js"></script>
6 <script> 6 <script>
7 var el1; 7 var el1;
8 var el2; 8 var el2;
9 function createDynamicElements() 9 function createDynamicElements()
10 { 10 {
(...skipping 24 matching lines...) Expand all
35 return selectedElement.node().getAttribute("id"); 35 return selectedElement.node().getAttribute("id");
36 } 36 }
37 37
38 function step1() 38 function step1()
39 { 39 {
40 InspectorTest.evaluateInConsole("inspect(el1)", step2); 40 InspectorTest.evaluateInConsole("inspect(el1)", step2);
41 } 41 }
42 42
43 function step2() 43 function step2()
44 { 44 {
45 InspectorTest.runAfterPendingDispatches(step3); 45 InspectorTest.deprecatedRunAfterPendingDispatches(step3);
46 } 46 }
47 47
48 function step3() 48 function step3()
49 { 49 {
50 var id = selectedNodeId(); 50 var id = selectedNodeId();
51 if (id === "main-frame-div") 51 if (id === "main-frame-div")
52 InspectorTest.addResult("PASS: selected node with id '" + id + "'") ; 52 InspectorTest.addResult("PASS: selected node with id '" + id + "'") ;
53 else 53 else
54 InspectorTest.addResult("FAIL: unexpected selection " + id); 54 InspectorTest.addResult("FAIL: unexpected selection " + id);
55 // Frame was changed to the iframe. Moving back to the top frame. 55 // Frame was changed to the iframe. Moving back to the top frame.
56 InspectorTest.evaluateInConsole("inspect(window.frameElement.parentEleme nt)", step4); 56 InspectorTest.evaluateInConsole("inspect(window.frameElement.parentEleme nt)", step4);
57 } 57 }
58 58
59 function step4() 59 function step4()
60 { 60 {
61 InspectorTest.runAfterPendingDispatches(step5); 61 InspectorTest.deprecatedRunAfterPendingDispatches(step5);
62 } 62 }
63 63
64 function step5() 64 function step5()
65 { 65 {
66 InspectorTest.evaluateInConsole("inspect(el2)", step6); 66 InspectorTest.evaluateInConsole("inspect(el2)", step6);
67 } 67 }
68 68
69 function step6() 69 function step6()
70 { 70 {
71 InspectorTest.runAfterPendingDispatches(step7); 71 InspectorTest.deprecatedRunAfterPendingDispatches(step7);
72 } 72 }
73 73
74 function step7() 74 function step7()
75 { 75 {
76 var id = selectedNodeId(); 76 var id = selectedNodeId();
77 if (id === "iframe-div") 77 if (id === "iframe-div")
78 InspectorTest.addResult("PASS: selected node with id '" + id + "'") ; 78 InspectorTest.addResult("PASS: selected node with id '" + id + "'") ;
79 else 79 else
80 InspectorTest.addResult("FAIL: unexpected selection " + id); 80 InspectorTest.addResult("FAIL: unexpected selection " + id);
81 InspectorTest.completeTest(); 81 InspectorTest.completeTest();
82 } 82 }
83 } 83 }
84 84
85 </script> 85 </script>
86 </head> 86 </head>
87 87
88 <body onload="runTest()"> 88 <body onload="runTest()">
89 <p>Test that web inspector can select element in an iframe even if the element w as created 89 <p>Test that web inspector can select element in an iframe even if the element w as created
90 via <code>createElement</code> of <code>document</code> other than iframe's <cod e>document</code>. 90 via <code>createElement</code> of <code>document</code> other than iframe's <cod e>document</code>.
91 <a href="https://bugs.webkit.org/show_bug.cgi?id=60031">Bug 60031</a> 91 <a href="https://bugs.webkit.org/show_bug.cgi?id=60031">Bug 60031</a>
92 </p> 92 </p>
93 <iframe style="width:400px"></iframe> 93 <iframe style="width:400px"></iframe>
94 </body> 94 </body>
95 </html> 95 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698