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

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

Issue 2570553002: Clear cache before running the test (Closed)
Patch Set: Addressed comments 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/inspector/network/network-filters.html » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/http/tests/inspector/network-test.js
diff --git a/third_party/WebKit/LayoutTests/http/tests/inspector/network-test.js b/third_party/WebKit/LayoutTests/http/tests/inspector/network-test.js
index 92ccdd6fa936ce7de68cf1bd036eb4796230e336..64078f95386d1b2089a18bb2514949f26f23e6e9 100644
--- a/third_party/WebKit/LayoutTests/http/tests/inspector/network-test.js
+++ b/third_party/WebKit/LayoutTests/http/tests/inspector/network-test.js
@@ -124,6 +124,14 @@ InspectorTest.makeFetch = function(url, requestInitializer, callback)
InspectorTest.callFunctionInPageAsync("makeFetch", [url, requestInitializer]).then(callback);
}
+InspectorTest.clearNetworkCache = function(finishedCallback)
+{
+ // This turns cache off and then on, effectively clearning the cache.
+ var networkAgent = InspectorTest.NetworkAgent;
+ networkAgent.setCacheDisabled(true, networkAgent.setCacheDisabled.bind(
+ networkAgent, false, finishedCallback));
+}
+
InspectorTest.HARPropertyFormatters = {
bodySize: "formatAsTypeName",
compression: "formatAsTypeName",
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/http/tests/inspector/network/network-filters.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698