Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(511)

Side by Side Diff: chrome/browser/extensions/extension_browsertests_misc.cc

Issue 7782026: Switch from chrome://extensions to chrome://settings/extensionSettings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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/file_util.h" 5 #include "base/file_util.h"
6 #include "base/memory/ref_counted.h" 6 #include "base/memory/ref_counted.h"
7 #include "base/utf_string_conversions.h" 7 #include "base/utf_string_conversions.h"
8 #include "chrome/browser/extensions/autoupdate_interceptor.h" 8 #include "chrome/browser/extensions/autoupdate_interceptor.h"
9 #include "chrome/browser/extensions/extension_apitest.h" 9 #include "chrome/browser/extensions/extension_apitest.h"
10 #include "chrome/browser/extensions/extension_browsertest.h" 10 #include "chrome/browser/extensions/extension_browsertest.h"
(...skipping 807 matching lines...) Expand 10 before | Expand all | Expand 10 after
818 // extension's options page. 818 // extension's options page.
819 // Disabled. See http://crbug.com/26948 for details. 819 // Disabled. See http://crbug.com/26948 for details.
820 IN_PROC_BROWSER_TEST_F(ExtensionBrowserTest, DISABLED_OptionsPage) { 820 IN_PROC_BROWSER_TEST_F(ExtensionBrowserTest, DISABLED_OptionsPage) {
821 // Install an extension with an options page. 821 // Install an extension with an options page.
822 ASSERT_TRUE(InstallExtension(test_data_dir_.AppendASCII("options.crx"), 1)); 822 ASSERT_TRUE(InstallExtension(test_data_dir_.AppendASCII("options.crx"), 1));
823 ExtensionService* service = browser()->profile()->GetExtensionService(); 823 ExtensionService* service = browser()->profile()->GetExtensionService();
824 const ExtensionList* extensions = service->extensions(); 824 const ExtensionList* extensions = service->extensions();
825 ASSERT_EQ(1u, extensions->size()); 825 ASSERT_EQ(1u, extensions->size());
826 const Extension* extension = extensions->at(0); 826 const Extension* extension = extensions->at(0);
827 827
828 // Go to the chrome://extensions page and click the Options button. 828 // Go to the Extension Settings page and click the Options button.
829 ui_test_utils::NavigateToURL(browser(), GURL(chrome::kChromeUIExtensionsURL)); 829 ui_test_utils::NavigateToURL(
830 browser(), GURL(std::string(chrome::kChromeUISettingsURL) +
831 chrome::kExtensionsSubPage));
830 TabStripModel* tab_strip = browser()->tabstrip_model(); 832 TabStripModel* tab_strip = browser()->tabstrip_model();
831 ASSERT_TRUE(ui_test_utils::ExecuteJavaScript( 833 ASSERT_TRUE(ui_test_utils::ExecuteJavaScript(
832 browser()->GetSelectedTabContents()->render_view_host(), L"", 834 browser()->GetSelectedTabContents()->render_view_host(), L"",
833 jscript_click_option_button)); 835 jscript_click_option_button));
834 836
835 // If the options page hasn't already come up, wait for it. 837 // If the options page hasn't already come up, wait for it.
836 if (tab_strip->count() == 1) { 838 if (tab_strip->count() == 1) {
837 ui_test_utils::WaitForNewTab(browser()); 839 ui_test_utils::WaitForNewTab(browser());
838 } 840 }
839 ASSERT_EQ(2, tab_strip->count()); 841 ASSERT_EQ(2, tab_strip->count());
840 842
841 EXPECT_EQ(extension->GetResourceURL("options.html"), 843 EXPECT_EQ(extension->GetResourceURL("options.html"),
842 tab_strip->GetTabContentsAt(1)->tab_contents()->GetURL()); 844 tab_strip->GetTabContentsAt(1)->tab_contents()->GetURL());
843 } 845 }
844 846
845 //============================================================================== 847 //==============================================================================
846 // STOP! Please do not add any more random-ass tests here. Create new files for 848 // STOP! Please do not add any more random-ass tests here. Create new files for
847 // your tests grouped by functionality. Also, you should strongly consider using 849 // your tests grouped by functionality. Also, you should strongly consider using
848 // ExtensionAPITest if possible. 850 // ExtensionAPITest if possible.
849 //============================================================================== 851 //==============================================================================
OLDNEW
« no previous file with comments | « chrome/browser/download/download_browsertest.cc ('k') | chrome/browser/extensions/extension_context_menu_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698