OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "chrome/browser/services/gcm/fake_gcm_profile_service.h" | 5 #include "chrome/browser/services/gcm/fake_gcm_profile_service.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
9 #include "base/strings/string_number_conversions.h" | 9 #include "base/strings/string_number_conversions.h" |
10 #include "chrome/browser/profiles/profile.h" | 10 #include "chrome/browser/profiles/profile.h" |
11 #include "chrome/browser/services/gcm/fake_gcm_client_factory.h" | 11 #include "components/gcm_driver/fake_gcm_client_factory.h" |
12 #include "content/public/browser/browser_context.h" | 12 #include "content/public/browser/browser_context.h" |
13 | 13 |
14 namespace gcm { | 14 namespace gcm { |
15 | 15 |
16 namespace { | 16 namespace { |
17 | 17 |
18 class FakeGCMDriver : public GCMDriver { | 18 class FakeGCMDriver : public GCMDriver { |
19 public: | 19 public: |
20 explicit FakeGCMDriver(FakeGCMProfileService* service); | 20 explicit FakeGCMDriver(FakeGCMProfileService* service); |
21 virtual ~FakeGCMDriver(); | 21 virtual ~FakeGCMDriver(); |
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
145 | 145 |
146 callback.Run(message.id, GCMClient::SUCCESS); | 146 callback.Run(message.id, GCMClient::SUCCESS); |
147 } | 147 } |
148 | 148 |
149 void FakeGCMProfileService::AddExpectedUnregisterResponse( | 149 void FakeGCMProfileService::AddExpectedUnregisterResponse( |
150 GCMClient::Result result) { | 150 GCMClient::Result result) { |
151 unregister_responses_.push_back(result); | 151 unregister_responses_.push_back(result); |
152 } | 152 } |
153 | 153 |
154 } // namespace gcm | 154 } // namespace gcm |
OLD | NEW |