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

Unified Diff: chrome/browser/services/gcm/fake_gcm_profile_service.cc

Issue 648623003: PushMessagingBrowserTest for registration success and failure (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git/+/master
Patch Set: Rebase and address Peter's feedback. Created 6 years, 2 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/services/gcm/fake_gcm_profile_service.cc
diff --git a/chrome/browser/services/gcm/fake_gcm_profile_service.cc b/chrome/browser/services/gcm/fake_gcm_profile_service.cc
index 584b90332c4b4e4b6918eab975015f0c159fbcd0..0123b696568b3c15a7a8f3ec1413bd935a32faac 100644
--- a/chrome/browser/services/gcm/fake_gcm_profile_service.cc
+++ b/chrome/browser/services/gcm/fake_gcm_profile_service.cc
@@ -112,7 +112,10 @@ KeyedService* FakeGCMProfileService::Build(content::BrowserContext* context) {
}
FakeGCMProfileService::FakeGCMProfileService(Profile* profile)
- : collect_(false) {}
+ : collect_(false) {
+ static_cast<PushMessagingServiceImpl*>(push_messaging_service())
+ ->SetProfileForTesting(profile);
+}
FakeGCMProfileService::~FakeGCMProfileService() {}

Powered by Google App Engine
This is Rietveld 408576698