OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/extensions/api/push_messaging/push_messaging_api.h" | 5 #include "chrome/browser/extensions/api/push_messaging/push_messaging_api.h" |
6 | 6 |
7 #include "apps/launcher.h" | 7 #include "apps/launcher.h" |
8 #include "base/strings/stringprintf.h" | 8 #include "base/strings/stringprintf.h" |
9 #include "chrome/browser/extensions/api/push_messaging/push_messaging_invalidati
on_handler.h" | 9 #include "chrome/browser/extensions/api/push_messaging/push_messaging_invalidati
on_handler.h" |
10 #include "chrome/browser/extensions/api/push_messaging/push_messaging_invalidati
on_mapper.h" | 10 #include "chrome/browser/extensions/api/push_messaging/push_messaging_invalidati
on_mapper.h" |
11 #include "chrome/browser/extensions/extension_apitest.h" | 11 #include "chrome/browser/extensions/extension_apitest.h" |
12 #include "chrome/browser/extensions/extension_test_message_listener.h" | |
13 #include "chrome/browser/invalidation/fake_invalidation_service.h" | 12 #include "chrome/browser/invalidation/fake_invalidation_service.h" |
14 #include "chrome/browser/invalidation/profile_invalidation_provider_factory.h" | 13 #include "chrome/browser/invalidation/profile_invalidation_provider_factory.h" |
15 #include "chrome/browser/profiles/profile.h" | 14 #include "chrome/browser/profiles/profile.h" |
16 #include "chrome/browser/ui/browser.h" | 15 #include "chrome/browser/ui/browser.h" |
17 #include "chrome/common/chrome_switches.h" | 16 #include "chrome/common/chrome_switches.h" |
18 #include "chrome/test/base/ui_test_utils.h" | 17 #include "chrome/test/base/ui_test_utils.h" |
19 #include "components/invalidation/fake_invalidator.h" | 18 #include "components/invalidation/fake_invalidator.h" |
20 #include "components/invalidation/invalidation.h" | 19 #include "components/invalidation/invalidation.h" |
21 #include "components/invalidation/invalidation_service.h" | 20 #include "components/invalidation/invalidation_service.h" |
22 #include "components/invalidation/profile_invalidation_provider.h" | 21 #include "components/invalidation/profile_invalidation_provider.h" |
23 #include "components/keyed_service/core/keyed_service.h" | 22 #include "components/keyed_service/core/keyed_service.h" |
| 23 #include "extensions/test/extension_test_message_listener.h" |
24 #include "extensions/test/result_catcher.h" | 24 #include "extensions/test/result_catcher.h" |
25 #include "google/cacheinvalidation/types.pb.h" | 25 #include "google/cacheinvalidation/types.pb.h" |
26 #include "testing/gmock/include/gmock/gmock.h" | 26 #include "testing/gmock/include/gmock/gmock.h" |
27 | 27 |
28 using ::testing::SaveArg; | 28 using ::testing::SaveArg; |
29 using ::testing::StrictMock; | 29 using ::testing::StrictMock; |
30 using ::testing::_; | 30 using ::testing::_; |
31 | 31 |
32 namespace content { | 32 namespace content { |
33 class BrowserContext; | 33 class BrowserContext; |
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
202 const extensions::Extension* extension = | 202 const extensions::Extension* extension = |
203 LoadExtension(test_data_dir_.AppendASCII("push_messaging")); | 203 LoadExtension(test_data_dir_.AppendASCII("push_messaging")); |
204 ASSERT_TRUE(extension); | 204 ASSERT_TRUE(extension); |
205 ui_test_utils::NavigateToURL( | 205 ui_test_utils::NavigateToURL( |
206 browser(), extension->GetResourceURL("get_channel_id.html")); | 206 browser(), extension->GetResourceURL("get_channel_id.html")); |
207 | 207 |
208 EXPECT_TRUE(catcher.GetNextResult()) << catcher.message(); | 208 EXPECT_TRUE(catcher.GetNextResult()) << catcher.message(); |
209 } | 209 } |
210 | 210 |
211 } // namespace extensions | 211 } // namespace extensions |
OLD | NEW |