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

Unified Diff: chrome/browser/extensions/api/instance_id/instance_id_apitest.cc

Issue 1851423003: Make Web Push use InstanceID tokens instead of GCM registrations (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@iid4default
Patch Set: Rebase Created 4 years, 3 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
Index: chrome/browser/extensions/api/instance_id/instance_id_apitest.cc
diff --git a/chrome/browser/extensions/api/instance_id/instance_id_apitest.cc b/chrome/browser/extensions/api/instance_id/instance_id_apitest.cc
index 63a4674329d9a3318a185764ad97694bff63dae5..26fcb689540cd658827e00de162fe0a396c4fbed 100644
--- a/chrome/browser/extensions/api/instance_id/instance_id_apitest.cc
+++ b/chrome/browser/extensions/api/instance_id/instance_id_apitest.cc
@@ -23,18 +23,6 @@ using extensions::ResultCatcher;
namespace extensions {
-namespace {
-
-std::unique_ptr<KeyedService> BuildFakeGCMProfileService(
- content::BrowserContext* context) {
- std::unique_ptr<gcm::FakeGCMProfileService> service(
- new gcm::FakeGCMProfileService(Profile::FromBrowserContext(context)));
- service->SetDriverForTesting(new instance_id::FakeGCMDriverForInstanceID());
- return std::move(service);
-}
-
-} // namespace
-
class InstanceIDApiTest : public ExtensionApiTest {
public:
InstanceIDApiTest();
@@ -51,7 +39,7 @@ InstanceIDApiTest::InstanceIDApiTest() {
void InstanceIDApiTest::SetUpOnMainThread() {
gcm::GCMProfileServiceFactory::GetInstance()->SetTestingFactory(
- browser()->profile(), &BuildFakeGCMProfileService);
+ browser()->profile(), &gcm::FakeGCMProfileService::Build);
ExtensionApiTest::SetUpOnMainThread();
}

Powered by Google App Engine
This is Rietveld 408576698