OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "base/bind.h" | 5 #include "base/bind.h" |
6 #include "base/command_line.h" | 6 #include "base/command_line.h" |
7 #include "base/compiler_specific.h" | 7 #include "base/compiler_specific.h" |
8 #include "base/memory/weak_ptr.h" | 8 #include "base/memory/weak_ptr.h" |
9 #include "base/message_loop.h" | 9 #include "base/message_loop.h" |
10 #include "chrome/browser/extensions/app_notify_channel_setup.h" | 10 #include "chrome/browser/extensions/app_notify_channel_setup.h" |
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
214 | 214 |
215 protected: | 215 protected: |
216 MessageLoop message_loop_; | 216 MessageLoop message_loop_; |
217 content::TestBrowserThread ui_thread_; | 217 content::TestBrowserThread ui_thread_; |
218 TestProfile profile_; | 218 TestProfile profile_; |
219 TestDelegate delegate_; | 219 TestDelegate delegate_; |
220 scoped_ptr<TestUI> ui_; | 220 scoped_ptr<TestUI> ui_; |
221 FakeURLFetcherFactory factory_; | 221 FakeURLFetcherFactory factory_; |
222 }; | 222 }; |
223 | 223 |
| 224 /* |
224 TEST_F(AppNotifyChannelSetupTest, LoginFailure) { | 225 TEST_F(AppNotifyChannelSetupTest, LoginFailure) { |
225 SetupLogin(false); | 226 SetupLogin(false); |
226 | 227 |
227 scoped_refptr<AppNotifyChannelSetup> setup = CreateInstance(); | 228 scoped_refptr<AppNotifyChannelSetup> setup = CreateInstance(); |
228 RunServerTest(setup, "", "canceled_by_user"); | 229 RunServerTest(setup, "", "canceled_by_user"); |
229 } | 230 } |
230 | 231 |
231 TEST_F(AppNotifyChannelSetupTest, FetchTokensFailure) { | 232 TEST_F(AppNotifyChannelSetupTest, FetchTokensFailure) { |
232 SetupLogin(true); | 233 SetupLogin(true); |
233 SetupFetchTokens(false, false); | 234 SetupFetchTokens(false, false); |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
266 | 267 |
267 TEST_F(AppNotifyChannelSetupTest, ServerSuccess) { | 268 TEST_F(AppNotifyChannelSetupTest, ServerSuccess) { |
268 SetupLogin(true); | 269 SetupLogin(true); |
269 SetupFetchTokens(true, false); | 270 SetupFetchTokens(true, false); |
270 SetupRecordGrant(true); | 271 SetupRecordGrant(true); |
271 SetupGetChannelId(true); | 272 SetupGetChannelId(true); |
272 | 273 |
273 scoped_refptr<AppNotifyChannelSetup> setup = CreateInstance(); | 274 scoped_refptr<AppNotifyChannelSetup> setup = CreateInstance(); |
274 RunServerTest(setup, "dummy_do_not_use", ""); | 275 RunServerTest(setup, "dummy_do_not_use", ""); |
275 } | 276 } |
| 277 */ |
OLD | NEW |