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

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/inspector-enabled/database-open.html

Issue 1880273002: [DevTools] Create last agents on attach, modify InspectorDatabaseAgent to support it. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: two databases in the test 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
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/inspector-enabled/database-open-expected.txt » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN"> 1 <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
2 <html> 2 <html>
3 <head> 3 <head>
4 <script src="../inspector/inspector-test.js"></script> 4 <script src="../inspector/inspector-test.js"></script>
5 <script src="../inspector/resources-test.js"></script> 5 <script src="../inspector/resources-test.js"></script>
6 6
7 <script> 7 <script>
8 8
9 function onload() 9 function onload()
10 { 10 {
11 if (window.testRunner) 11 if (window.testRunner)
12 testRunner.waitUntilDone(); 12 testRunner.waitUntilDone();
13 13
14 var db = openDatabase("InspectorDatabaseTest", "1.0", "Test of database inst rumentation", 1); 14 var db = openDatabase("InspectorDatabaseTest", "1.0", "Test of database inst rumentation", 1);
15 var db2 = openDatabase("InspectorDatabaseTest2", "1.0", "Test of database in strumentation 2", 1);
15 16
16 if (window.testRunner) 17 if (window.testRunner)
17 testRunner.showWebInspector(); 18 testRunner.showWebInspector();
18 runTest(); 19 runTest();
19 } 20 }
20 21
21 function test() 22 function test()
22 { 23 {
23 InspectorTest.databaseModel().enable(); 24 InspectorTest.databaseModel().enable();
24 function run() 25 function run()
25 { 26 {
27 function compareByName(d1, d2)
28 {
29 if (d1.name < d2.name)
30 return -1;
31 if (d1.name > d2.name)
32 return 1;
33 return 0;
34 }
35
26 var databases = InspectorTest.databaseModel().databases(); 36 var databases = InspectorTest.databaseModel().databases();
37 databases.sort(compareByName);
27 for (var i = 0; i < databases.length; ++i) { 38 for (var i = 0; i < databases.length; ++i) {
28 InspectorTest.addResult("Name: " + databases[i].name); 39 InspectorTest.addResult("Name: " + databases[i].name);
29 InspectorTest.addResult("Version: " + databases[i].version); 40 InspectorTest.addResult("Version: " + databases[i].version);
30 InspectorTest.addResult("Domain: " + databases[i].domain); 41 InspectorTest.addResult("Domain: " + databases[i].domain);
31 } 42 }
32 InspectorTest.completeTest(); 43 InspectorTest.completeTest();
33 } 44 }
34 InspectorTest.runAfterPendingDispatches(run); 45 InspectorTest.runAfterPendingDispatches(run);
35 } 46 }
36 47
37 </script> 48 </script>
38 49
39 </head> 50 </head>
40 <body onload="onload()"> 51 <body onload="onload()">
41 <p>Tests that Web Inspector gets populated with databases that were opened befor e inspector is shown.</p> 52 <p>Tests that Web Inspector gets populated with databases that were opened befor e inspector is shown.</p>
42 </body> 53 </body>
43 </html> 54 </html>
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/inspector-enabled/database-open-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698