| 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 "base/command_line.h" | 5 #include "base/command_line.h" |
| 6 #include "chrome/browser/extensions/browser_action_test_util.h" | 6 #include "chrome/browser/extensions/browser_action_test_util.h" |
| 7 #include "chrome/browser/extensions/extension_apitest.h" | 7 #include "chrome/browser/extensions/extension_apitest.h" |
| 8 #include "chrome/browser/extensions/extension_browser_event_router.h" | 8 #include "chrome/browser/extensions/extension_browser_event_router.h" |
| 9 #include "chrome/browser/extensions/extension_service.h" | 9 #include "chrome/browser/extensions/extension_service.h" |
| 10 #include "chrome/browser/extensions/extension_tab_util.h" | 10 #include "chrome/browser/extensions/extension_tab_util.h" |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 | 25 |
| 26 namespace { | 26 namespace { |
| 27 | 27 |
| 28 class PageAsBrowserActionApiTest : public ExtensionApiTest { | 28 class PageAsBrowserActionApiTest : public ExtensionApiTest { |
| 29 public: | 29 public: |
| 30 PageAsBrowserActionApiTest() {} | 30 PageAsBrowserActionApiTest() {} |
| 31 virtual ~PageAsBrowserActionApiTest() {} | 31 virtual ~PageAsBrowserActionApiTest() {} |
| 32 | 32 |
| 33 void SetUpCommandLine(CommandLine* command_line) OVERRIDE { | 33 void SetUpCommandLine(CommandLine* command_line) OVERRIDE { |
| 34 ExtensionApiTest::SetUpCommandLine(command_line); | 34 ExtensionApiTest::SetUpCommandLine(command_line); |
| 35 command_line->AppendSwitch(switches::kEnableBrowserActionsForAll); | 35 command_line->AppendSwitch(switches::kEnableActionBox); |
| 36 } | 36 } |
| 37 | 37 |
| 38 protected: | 38 protected: |
| 39 BrowserActionTestUtil GetBrowserActionsBar() { | 39 BrowserActionTestUtil GetBrowserActionsBar() { |
| 40 return BrowserActionTestUtil(browser()); | 40 return BrowserActionTestUtil(browser()); |
| 41 } | 41 } |
| 42 }; | 42 }; |
| 43 | 43 |
| 44 IN_PROC_BROWSER_TEST_F(PageAsBrowserActionApiTest, Basic) { | 44 IN_PROC_BROWSER_TEST_F(PageAsBrowserActionApiTest, Basic) { |
| 45 ASSERT_TRUE(test_server()->Start()); | 45 ASSERT_TRUE(test_server()->Start()); |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 165 const Extension* extension = GetSingleLoadedExtension(); | 165 const Extension* extension = GetSingleLoadedExtension(); |
| 166 ASSERT_TRUE(extension) << message_; | 166 ASSERT_TRUE(extension) << message_; |
| 167 | 167 |
| 168 ResultCatcher catcher; | 168 ResultCatcher catcher; |
| 169 ui_test_utils::NavigateToURL(browser(), | 169 ui_test_utils::NavigateToURL(browser(), |
| 170 GURL(extension->GetResourceURL("update.html"))); | 170 GURL(extension->GetResourceURL("update.html"))); |
| 171 ASSERT_TRUE(catcher.GetNextResult()); | 171 ASSERT_TRUE(catcher.GetNextResult()); |
| 172 } | 172 } |
| 173 | 173 |
| 174 } | 174 } |
| OLD | NEW |