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/browser_event_router.h" |
5 #include "chrome/browser/extensions/extension_apitest.h" | 6 #include "chrome/browser/extensions/extension_apitest.h" |
6 #include "chrome/browser/extensions/extension_browser_event_router.h" | |
7 #include "chrome/browser/extensions/extension_service.h" | 7 #include "chrome/browser/extensions/extension_service.h" |
8 #include "chrome/browser/profiles/profile.h" | 8 #include "chrome/browser/profiles/profile.h" |
9 #include "chrome/browser/ui/browser.h" | 9 #include "chrome/browser/ui/browser.h" |
10 #include "chrome/browser/ui/browser_tabstrip.h" | 10 #include "chrome/browser/ui/browser_tabstrip.h" |
11 #include "chrome/browser/ui/tab_contents/tab_contents.h" | 11 #include "chrome/browser/ui/tab_contents/tab_contents.h" |
12 #include "chrome/common/extensions/extension.h" | 12 #include "chrome/common/extensions/extension.h" |
13 #include "chrome/common/extensions/extension_action.h" | 13 #include "chrome/common/extensions/extension_action.h" |
14 #include "chrome/test/base/ui_test_utils.h" | 14 #include "chrome/test/base/ui_test_utils.h" |
15 #include "content/public/browser/web_contents.h" | 15 #include "content/public/browser/web_contents.h" |
16 | 16 |
(...skipping 26 matching lines...) Expand all Loading... |
43 | 43 |
44 { | 44 { |
45 // Simulate the script badge being clicked. | 45 // Simulate the script badge being clicked. |
46 ResultCatcher catcher; | 46 ResultCatcher catcher; |
47 ExtensionService* service = browser()->profile()->GetExtensionService(); | 47 ExtensionService* service = browser()->profile()->GetExtensionService(); |
48 service->browser_event_router()->ScriptBadgeExecuted( | 48 service->browser_event_router()->ScriptBadgeExecuted( |
49 browser()->profile(), *script_badge, tab_id); | 49 browser()->profile(), *script_badge, tab_id); |
50 EXPECT_TRUE(catcher.GetNextResult()); | 50 EXPECT_TRUE(catcher.GetNextResult()); |
51 } | 51 } |
52 } | 52 } |
OLD | NEW |