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

Unified Diff: components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.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 (main conflics in browsertest and PMMF) Created 4 years, 7 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: components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.cc
diff --git a/components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.cc b/components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.cc
index 0ee7f0b6320f07f2dafc1f3e97a0102ddd48b5cc..90a406332ca59753f5fea08acb8b8e1cf1f50c0c 100644
--- a/components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.cc
+++ b/components/gcm_driver/instance_id/fake_gcm_driver_for_instance_id.cc
@@ -17,6 +17,10 @@ namespace instance_id {
FakeGCMDriverForInstanceID::FakeGCMDriverForInstanceID()
: gcm::FakeGCMDriver(base::ThreadTaskRunnerHandle::Get()) {}
+FakeGCMDriverForInstanceID::FakeGCMDriverForInstanceID(
+ const scoped_refptr<base::SequencedTaskRunner>& blocking_task_runner)
+ : FakeGCMDriver(blocking_task_runner) {}
+
FakeGCMDriverForInstanceID::~FakeGCMDriverForInstanceID() {
}
@@ -67,6 +71,9 @@ void FakeGCMDriverForInstanceID::GetToken(
tokens_[key] = token;
}
+ last_gettoken_app_id_ = app_id;
+ last_gettoken_authorized_entity_ = authorized_entity;
+
base::ThreadTaskRunnerHandle::Get()->PostTask(
FROM_HERE, base::Bind(callback, token, gcm::GCMClient::SUCCESS));
}

Powered by Google App Engine
This is Rietveld 408576698