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

Side by Side Diff: content/browser/service_worker/service_worker_browsertest.cc

Issue 2451373003: service worker: Implement NavigationPreloadManager.setHeaderValue (Closed)
Patch Set: rebase 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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <stddef.h> 5 #include <stddef.h>
6 #include <stdint.h> 6 #include <stdint.h>
7 7
8 #include <map> 8 #include <map>
9 #include <memory> 9 #include <memory>
10 #include <utility> 10 #include <utility>
(...skipping 1487 matching lines...) Expand 10 before | Expand all | Expand 10 after
1498 scope, base::Bind(&self::DidFindRegistrationForEnableNavigationPreload, 1498 scope, base::Bind(&self::DidFindRegistrationForEnableNavigationPreload,
1499 base::Unretained(this), continuation)); 1499 base::Unretained(this), continuation));
1500 } 1500 }
1501 1501
1502 void DidFindRegistrationForEnableNavigationPreload( 1502 void DidFindRegistrationForEnableNavigationPreload(
1503 const base::Closure& continuation, 1503 const base::Closure& continuation,
1504 ServiceWorkerStatusCode status, 1504 ServiceWorkerStatusCode status,
1505 scoped_refptr<ServiceWorkerRegistration> registration) { 1505 scoped_refptr<ServiceWorkerRegistration> registration) {
1506 EXPECT_EQ(SERVICE_WORKER_OK, status); 1506 EXPECT_EQ(SERVICE_WORKER_OK, status);
1507 ASSERT_TRUE(registration->active_version()); 1507 ASSERT_TRUE(registration->active_version());
1508 registration->active_version()->set_navigation_preload_enabled(true); 1508 registration->EnableNavigationPreload(true);
1509 continuation.Run(); 1509 continuation.Run();
1510 } 1510 }
1511 1511
1512 std::unique_ptr<net::test_server::HttpResponse> StaticRequestHandler( 1512 std::unique_ptr<net::test_server::HttpResponse> StaticRequestHandler(
1513 const GURL& url, 1513 const GURL& url,
1514 const std::string& content, 1514 const std::string& content,
1515 const std::string& content_type, 1515 const std::string& content_type,
1516 const net::test_server::HttpRequest& request) const { 1516 const net::test_server::HttpRequest& request) const {
1517 const GURL absolute_url = 1517 const GURL absolute_url =
1518 embedded_test_server()->GetURL(request.relative_url); 1518 embedded_test_server()->GetURL(request.relative_url);
(...skipping 1113 matching lines...) Expand 10 before | Expand all | Expand 10 after
2632 ServiceWorkerV8CacheStrategiesNormalTest, 2632 ServiceWorkerV8CacheStrategiesNormalTest,
2633 ::testing::Values(true, false)); 2633 ::testing::Values(true, false));
2634 INSTANTIATE_TEST_CASE_P(ServiceWorkerBrowserTest, 2634 INSTANTIATE_TEST_CASE_P(ServiceWorkerBrowserTest,
2635 ServiceWorkerV8CacheStrategiesAggressiveTest, 2635 ServiceWorkerV8CacheStrategiesAggressiveTest,
2636 ::testing::Values(true, false)); 2636 ::testing::Values(true, false));
2637 INSTANTIATE_TEST_CASE_P(ServiceWorkerBrowserTest, 2637 INSTANTIATE_TEST_CASE_P(ServiceWorkerBrowserTest,
2638 ServiceWorkerDisableWebSecurityTest, 2638 ServiceWorkerDisableWebSecurityTest,
2639 ::testing::Values(true, false)); 2639 ::testing::Values(true, false));
2640 2640
2641 } // namespace content 2641 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/bad_message.h ('k') | content/browser/service_worker/service_worker_dispatcher_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698