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

Side by Side Diff: chrome/browser/infobars/infobars_browsertest.cc

Issue 10683003: Moved CrxInstaller and CrxInstallerError into extensions namespace (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Latest-er master Created 8 years, 5 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
OLDNEW
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/crx_installer.h" 5 #include "chrome/browser/extensions/crx_installer.h"
6 #include "chrome/browser/extensions/extension_install_prompt.h" 6 #include "chrome/browser/extensions/extension_install_prompt.h"
7 #include "chrome/browser/extensions/extension_service.h" 7 #include "chrome/browser/extensions/extension_service.h"
8 #include "chrome/browser/infobars/infobar_tab_helper.h" 8 #include "chrome/browser/infobars/infobar_tab_helper.h"
9 #include "chrome/browser/themes/theme_service.h" 9 #include "chrome/browser/themes/theme_service.h"
10 #include "chrome/browser/themes/theme_service_factory.h" 10 #include "chrome/browser/themes/theme_service_factory.h"
(...skipping 23 matching lines...) Expand all
34 FilePath().AppendASCII("extensions"), FilePath().AppendASCII(filename)); 34 FilePath().AppendASCII("extensions"), FilePath().AppendASCII(filename));
35 Profile* profile = browser()->profile(); 35 Profile* profile = browser()->profile();
36 ExtensionService* service = profile->GetExtensionService(); 36 ExtensionService* service = profile->GetExtensionService();
37 37
38 content::WindowedNotificationObserver observer( 38 content::WindowedNotificationObserver observer(
39 chrome::NOTIFICATION_EXTENSION_LOADED, 39 chrome::NOTIFICATION_EXTENSION_LOADED,
40 content::NotificationService::AllSources()); 40 content::NotificationService::AllSources());
41 41
42 ExtensionInstallPrompt* client = 42 ExtensionInstallPrompt* client =
43 chrome::CreateExtensionInstallPromptWithBrowser(browser()); 43 chrome::CreateExtensionInstallPromptWithBrowser(browser());
44 scoped_refptr<CrxInstaller> installer( 44 scoped_refptr<extensions::CrxInstaller> installer(
45 CrxInstaller::Create(service, client)); 45 extensions::CrxInstaller::Create(service, client));
46 installer->set_install_cause(extension_misc::INSTALL_CAUSE_AUTOMATION); 46 installer->set_install_cause(extension_misc::INSTALL_CAUSE_AUTOMATION);
47 installer->InstallCrx(path); 47 installer->InstallCrx(path);
48 48
49 observer.Wait(); 49 observer.Wait();
50 } 50 }
51 }; 51 };
52 52
53 IN_PROC_BROWSER_TEST_F(InfoBarsTest, TestInfoBarsCloseOnNewTheme) { 53 IN_PROC_BROWSER_TEST_F(InfoBarsTest, TestInfoBarsCloseOnNewTheme) {
54 ASSERT_TRUE(test_server()->Start()); 54 ASSERT_TRUE(test_server()->Start());
55 55
(...skipping 24 matching lines...) Expand all
80 80
81 content::WindowedNotificationObserver infobar_removed_2( 81 content::WindowedNotificationObserver infobar_removed_2(
82 chrome::NOTIFICATION_TAB_CONTENTS_INFOBAR_REMOVED, 82 chrome::NOTIFICATION_TAB_CONTENTS_INFOBAR_REMOVED,
83 content::NotificationService::AllSources()); 83 content::NotificationService::AllSources());
84 ThemeServiceFactory::GetForProfile(browser()->profile())->UseDefaultTheme(); 84 ThemeServiceFactory::GetForProfile(browser()->profile())->UseDefaultTheme();
85 infobar_removed_2.Wait(); 85 infobar_removed_2.Wait();
86 EXPECT_EQ(0u, 86 EXPECT_EQ(0u,
87 chrome::GetActiveTabContents(browser())->infobar_tab_helper()-> 87 chrome::GetActiveTabContents(browser())->infobar_tab_helper()->
88 infobar_count()); 88 infobar_count());
89 } 89 }
OLDNEW
« no previous file with comments | « chrome/browser/extensions/test_extension_service.cc ('k') | chrome/browser/performance_monitor/performance_monitor.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698