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

Side by Side Diff: third_party/WebKit/LayoutTests/http/tests/inspector/network-test.js

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 // This goes before everything else to keep console message line number invarian t. 1 // This goes before everything else to keep console message line number invarian t.
2 var lastXHRIndex = 0; 2 var lastXHRIndex = 0;
3 function xhrLoadedCallback() 3 function xhrLoadedCallback()
4 { 4 {
5 // We need to make sure the console message text is unique so that we don't end up with repeat count update only. 5 // We need to make sure the console message text is unique so that we don't end up with repeat count update only.
6 console.log("XHR loaded: " + (++lastXHRIndex)); 6 console.log("XHR loaded: " + (++lastXHRIndex));
7 } 7 }
8 8
9 function makeSimpleXHR(method, url, async, callback) 9 function makeSimpleXHR(method, url, async, callback)
10 { 10 {
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 { 47 {
48 return fetch(url, requestInitializer).catch(e => e); 48 return fetch(url, requestInitializer).catch(e => e);
49 } 49 }
50 50
51 var initialize_NetworkTest = function() { 51 var initialize_NetworkTest = function() {
52 52
53 InspectorTest.preloadPanel("network"); 53 InspectorTest.preloadPanel("network");
54 54
55 InspectorTest.recordNetwork = function() 55 InspectorTest.recordNetwork = function()
56 { 56 {
57 WebInspector.panels.network._networkLogView.setRecording(true); 57 UI.panels.network._networkLogView.setRecording(true);
58 } 58 }
59 59
60 InspectorTest.networkRequests = function() 60 InspectorTest.networkRequests = function()
61 { 61 {
62 return WebInspector.NetworkLog.requests(); 62 return SDK.NetworkLog.requests();
63 } 63 }
64 64
65 InspectorTest.dumpNetworkRequests = function() 65 InspectorTest.dumpNetworkRequests = function()
66 { 66 {
67 var requests = InspectorTest.networkRequests(); 67 var requests = InspectorTest.networkRequests();
68 requests.sort(function(a, b) {return a.url.localeCompare(b.url);}); 68 requests.sort(function(a, b) {return a.url.localeCompare(b.url);});
69 InspectorTest.addResult("resources count = " + requests.length); 69 InspectorTest.addResult("resources count = " + requests.length);
70 for (i = 0; i < requests.length; i++) 70 for (i = 0; i < requests.length; i++)
71 InspectorTest.addResult(requests[i].url); 71 InspectorTest.addResult(requests[i].url);
72 } 72 }
(...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 version: "formatAsTypeName", 136 version: "formatAsTypeName",
137 wait: "formatAsTypeName", 137 wait: "formatAsTypeName",
138 _transferSize: "formatAsTypeName", 138 _transferSize: "formatAsTypeName",
139 _error: "skip" 139 _error: "skip"
140 }; 140 };
141 // addObject checks own properties only, so make a deep copy rather than use pro totype. 141 // addObject checks own properties only, so make a deep copy rather than use pro totype.
142 InspectorTest.HARPropertyFormattersWithSize = JSON.parse(JSON.stringify(Inspecto rTest.HARPropertyFormatters)); 142 InspectorTest.HARPropertyFormattersWithSize = JSON.parse(JSON.stringify(Inspecto rTest.HARPropertyFormatters));
143 InspectorTest.HARPropertyFormattersWithSize.size = "formatAsTypeName"; 143 InspectorTest.HARPropertyFormattersWithSize.size = "formatAsTypeName";
144 144
145 }; 145 };
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698