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

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/inspector/persistence/persistence-tabbed-editor-opens-filesystem-uisourcecode.html

Issue 2551233002: DevTools: show filesystem file by default (Closed)
Patch Set: nit Created 4 years 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="../inspector-test.js"></script> 3 <script src="../inspector-test.js"></script>
4 <script src="../debugger-test.js"></script> 4 <script src="../debugger-test.js"></script>
5 <script src="../isolated-filesystem-test.js"></script> 5 <script src="../isolated-filesystem-test.js"></script>
6 <script src="./persistence-test.js"></script> 6 <script src="./persistence-test.js"></script>
7 <script src="./resources/foo.js"></script> 7 <script src="./resources/foo.js"></script>
8 <script> 8 <script>
9 9
10 function test() 10 function test()
11 { 11 {
12 var fs = new InspectorTest.TestFileSystem("file:///var/www"); 12 var fs = new InspectorTest.TestFileSystem("file:///var/www");
13 var fsEntry = InspectorTest.addFooJSFile(fs); 13 var fsEntry = InspectorTest.addFooJSFile(fs);
14 fs.addFileMapping("http://127.0.0.1:8000", "/"); 14 fs.addFileMapping("http://127.0.0.1:8000", "/");
15 fs.reportCreated(function() { }); 15 fs.reportCreated(function() { });
16 InspectorTest.waitForBinding("foo.js").then(onBindingCreated); 16 InspectorTest.waitForBinding("foo.js").then(onBindingCreated);
17 17
18 function onBindingCreated(binding) 18 function onBindingCreated(binding)
19 { 19 {
20 InspectorTest.addResult("Binding created: " + binding); 20 InspectorTest.addResult("Binding created: " + binding);
21 dumpEditorTabs("Opened tabs before opening any UISourceCodes:"); 21 dumpEditorTabs("Opened tabs before opening any UISourceCodes:");
22 InspectorTest.addResult("request open uiSourceCode: " + binding.fileSyst em.url()); 22 InspectorTest.addResult("request open uiSourceCode: " + binding.fileSyst em.url());
23 UI.panels.sources.showUISourceCode(binding.fileSystem, 0, 0); 23 UI.panels.sources.showUISourceCode(binding.network, 0, 0);
24 dumpEditorTabs("Opened tabs after opening UISourceCode:"); 24 dumpEditorTabs("Opened tabs after opening UISourceCode:");
25 InspectorTest.completeTest(); 25 InspectorTest.completeTest();
26 } 26 }
27 27
28 function dumpEditorTabs(title) 28 function dumpEditorTabs(title)
29 { 29 {
30 var editorContainer = UI.panels.sources._sourcesView._editorContainer; 30 var editorContainer = UI.panels.sources._sourcesView._editorContainer;
31 var openedUISourceCodes = editorContainer._tabIds.keysArray(); 31 var openedUISourceCodes = editorContainer._tabIds.keysArray();
32 openedUISourceCodes.sort((a, b) => a.url().compareTo(b.url())); 32 openedUISourceCodes.sort((a, b) => a.url().compareTo(b.url()));
33 InspectorTest.addResult(title); 33 InspectorTest.addResult(title);
34 for (code of openedUISourceCodes) 34 for (code of openedUISourceCodes)
35 InspectorTest.addResult(" " + code.url()); 35 InspectorTest.addResult(" " + code.url());
36 } 36 }
37 }; 37 };
38 </script> 38 </script>
39 </head> 39 </head>
40 <body onload="runTest()"> 40 <body onload="runTest()">
41 <p>Verify that for a fileSystem UISourceCode with network binding TabbedEditorCo ntainer opens network UISourceCode.</p> 41 <p>Verify that for a fileSystem UISourceCode with persistence binding TabbedEdit orContainer opens filesystem UISourceCode.</p>
42 </body> 42 </body>
43 </html> 43 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698