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

Unified Diff: chrome/browser/chrome_service_worker_browsertest.cc

Issue 2771823002: Implement updateViaCache flag and no-cache by default for main service worker scripts
Patch Set: fix IPC Created 3 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/DEPS ('k') | content/browser/DEPS » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chrome_service_worker_browsertest.cc
diff --git a/chrome/browser/chrome_service_worker_browsertest.cc b/chrome/browser/chrome_service_worker_browsertest.cc
index eb79a33ee3abf424a4f8f6d8abae790ef51e142f..4b7939fd0bf2761f82b3bb52196f7a48d57d2459 100644
--- a/chrome/browser/chrome_service_worker_browsertest.cc
+++ b/chrome/browser/chrome_service_worker_browsertest.cc
@@ -34,6 +34,7 @@
#include "content/public/test/browser_test_utils.h"
#include "net/test/embedded_test_server/embedded_test_server.h"
#include "ppapi/shared_impl/ppapi_switches.h"
+#include "third_party/WebKit/public/platform/modules/serviceworker/WebServiceWorkerUpdateViaCache.h"
namespace {
@@ -117,6 +118,7 @@ IN_PROC_BROWSER_TEST_F(ChromeServiceWorkerTest,
GetServiceWorkerContext()->RegisterServiceWorker(
embedded_test_server()->GetURL("/"),
embedded_test_server()->GetURL("/service_worker.js"),
+ blink::WebServiceWorkerUpdateViaCache::kImports,
base::Bind(&ExpectResultAndRun<bool>, true, run_loop.QuitClosure()));
run_loop.Run();
@@ -141,6 +143,7 @@ IN_PROC_BROWSER_TEST_F(ChromeServiceWorkerTest,
GetServiceWorkerContext()->RegisterServiceWorker(
embedded_test_server()->GetURL("/"),
embedded_test_server()->GetURL("/service_worker.js"),
+ blink::WebServiceWorkerUpdateViaCache::kImports,
base::Bind(&ExpectResultAndRun<bool>, true, run_loop.QuitClosure()));
run_loop.Run();
@@ -168,6 +171,7 @@ IN_PROC_BROWSER_TEST_F(ChromeServiceWorkerTest,
GetServiceWorkerContext()->RegisterServiceWorker(
embedded_test_server()->GetURL("/"),
embedded_test_server()->GetURL("/service_worker.js"),
+ blink::WebServiceWorkerUpdateViaCache::kImports,
base::Bind(&ExpectResultAndRun<bool>, false, run_loop.QuitClosure()));
run_loop.Run();
}
@@ -683,6 +687,7 @@ IN_PROC_BROWSER_TEST_F(ChromeServiceWorkerNavigationHintTest,
GetServiceWorkerContext()->RegisterServiceWorker(
embedded_test_server()->GetURL("/scope/"),
embedded_test_server()->GetURL("/sw.js"),
+ blink::WebServiceWorkerUpdateViaCache::kImports,
base::Bind(&ExpectResultAndRun<bool>, true, run_loop.QuitClosure()));
run_loop.Run();
RunNavigationHintTest("/scope/",
« no previous file with comments | « chrome/browser/DEPS ('k') | content/browser/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698