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

Side by Side Diff: third_party/WebKit/LayoutTests/inspector/elements/move-node.html

Issue 2493373002: DevTools: rename WebInspector into modules. (Closed)
Patch Set: for bots Created 4 years, 1 month 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/elements-test.js"></script> 4 <script src="../../http/tests/inspector/elements-test.js"></script>
5 <script> 5 <script>
6 6
7 function test() 7 function test()
8 { 8 {
9 var containerNode; 9 var containerNode;
10 10
11 InspectorTest.runTestSuite([ 11 InspectorTest.runTestSuite([
12 function testDumpInitial(next) 12 function testDumpInitial(next)
13 { 13 {
14 function callback(node) 14 function callback(node)
15 { 15 {
16 containerNode = InspectorTest.expandedNodeWithId("container"); 16 containerNode = InspectorTest.expandedNodeWithId("container");
17 17
18 InspectorTest.addResult("========= Original ========"); 18 InspectorTest.addResult("========= Original ========");
19 InspectorTest.dumpElementsTree(containerNode); 19 InspectorTest.dumpElementsTree(containerNode);
20 next(); 20 next();
21 } 21 }
22 InspectorTest.expandElementsTree(callback); 22 InspectorTest.expandElementsTree(callback);
23 }, 23 },
24 24
25 function testDragAndDrop(next) 25 function testDragAndDrop(next)
26 { 26 {
27 var treeOutline = InspectorTest.firstElementsTreeOutline(); 27 var treeOutline = InspectorTest.firstElementsTreeOutline();
28 treeOutline.addEventListener(WebInspector.ElementsTreeOutline.Events .SelectedNodeChanged, selectionChanged); 28 treeOutline.addEventListener(Elements.ElementsTreeOutline.Events.Sel ectedNodeChanged, selectionChanged);
29 29
30 function selectionChanged() 30 function selectionChanged()
31 { 31 {
32 InspectorTest.addResult("===== Moved child2 ====="); 32 InspectorTest.addResult("===== Moved child2 =====");
33 InspectorTest.dumpElementsTree(containerNode); 33 InspectorTest.dumpElementsTree(containerNode);
34 InspectorTest.addResult("Selection: " + WebInspector.DOMPresenta tionUtils.fullQualifiedSelector(treeOutline.selectedDOMNode())); 34 InspectorTest.addResult("Selection: " + Components.DOMPresentati onUtils.fullQualifiedSelector(treeOutline.selectedDOMNode()));
35 next(); 35 next();
36 } 36 }
37 37
38 var child2 = InspectorTest.expandedNodeWithId("child2"); 38 var child2 = InspectorTest.expandedNodeWithId("child2");
39 var child4 = InspectorTest.expandedNodeWithId("child4"); 39 var child4 = InspectorTest.expandedNodeWithId("child4");
40 treeOutline._treeElementBeingDragged = child2[treeOutline._treeEleme ntSymbol]; 40 treeOutline._treeElementBeingDragged = child2[treeOutline._treeEleme ntSymbol];
41 var treeElementToDropOn = child4[treeOutline._treeElementSymbol]; 41 var treeElementToDropOn = child4[treeOutline._treeElementSymbol];
42 treeOutline._doMove(treeElementToDropOn); 42 treeOutline._doMove(treeElementToDropOn);
43 } 43 }
44 ]); 44 ]);
45 } 45 }
46 46
47 </script> 47 </script>
48 </head> 48 </head>
49 49
50 <body onload="runTest()"> 50 <body onload="runTest()">
51 <p> 51 <p>
52 Tests elements drag and drop operation internals, verifies post-move selection. 52 Tests elements drag and drop operation internals, verifies post-move selection.
53 </p> 53 </p>
54 54
55 <div id="container"> 55 <div id="container">
56 <div id="child1"></div> 56 <div id="child1"></div>
57 <div id="child2"></div> 57 <div id="child2"></div>
58 <div id="child3"></div> 58 <div id="child3"></div>
59 <div id="child4"></div> 59 <div id="child4"></div>
60 </div> 60 </div>
61 61
62 </body> 62 </body>
63 </html> 63 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698