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

Unified Diff: ash/test/test_suite.cc

Issue 15755016: Introduce a single call to grab default browser on Win8 for tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review Created 7 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/test/test_suite.h ('k') | win8/test/metro_registration_helper.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/test/test_suite.cc
diff --git a/ash/test/test_suite.cc b/ash/test/test_suite.cc
index 458aaebcba889dd2488f73e76bc2e8d52a03b61a..66d9769b48b3f44c8a31f3502064be999560fa7c 100644
--- a/ash/test/test_suite.cc
+++ b/ash/test/test_suite.cc
@@ -24,7 +24,6 @@
#include "base/win/windows_version.h"
#include "ui/base/win/atl_module.h"
#include "win8/test/metro_registration_helper.h"
-#include "win8/test/open_with_dialog_controller.h"
#include "win8/test/test_registrar_constants.h"
#endif
@@ -41,16 +40,9 @@ void AuraShellTestSuite::Initialize() {
if (base::win::GetVersion() >= base::win::VERSION_WIN8 &&
!CommandLine::ForCurrentProcess()->HasSwitch(
ash::switches::kForceAshToDesktop)) {
- ASSERT_TRUE(win8::RegisterTestDefaultBrowser(
- win8::test::kDefaultTestAppUserModelId,
- win8::test::kDefaultTestExeName));
-
+ com_initializer_.reset(new base::win::ScopedCOMInitializer());
ui::win::CreateATLModuleIfNeeded();
-
- std::vector<base::string16> choices;
- win8::OpenWithDialogController controller;
- controller.RunSynchronously(NULL, L"http", win8::test::kDefaultTestExeName,
- &choices);
+ ASSERT_TRUE(win8::MakeTestDefaultBrowserSynchronously());
}
#endif
@@ -71,6 +63,9 @@ void AuraShellTestSuite::Initialize() {
void AuraShellTestSuite::Shutdown() {
ui::CompositorTestSupport::Terminate();
ui::ResourceBundle::CleanupSharedInstance();
+#if defined(OS_WIN)
+ com_initializer_.reset();
+#endif
base::TestSuite::Shutdown();
}
« no previous file with comments | « ash/test/test_suite.h ('k') | win8/test/metro_registration_helper.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698