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

Side by Side Diff: chrome/test/base/in_process_browser_test.cc

Issue 2808823002: MacViews: Allows the toolkit-views Manage Passwords Dialog to be used (Closed)
Patch Set: MacViews: Allows the toolkit-views Manage Passwords Dialog to be used (rebase) Created 3 years, 8 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/test/base/in_process_browser_test.h" 5 #include "chrome/test/base/in_process_browser_test.h"
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/feature_list.h" 10 #include "base/feature_list.h"
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 #include "content/public/common/content_switches.h" 58 #include "content/public/common/content_switches.h"
59 #include "content/public/test/browser_test_utils.h" 59 #include "content/public/test/browser_test_utils.h"
60 #include "content/public/test/test_launcher.h" 60 #include "content/public/test/test_launcher.h"
61 #include "content/public/test/test_navigation_observer.h" 61 #include "content/public/test/test_navigation_observer.h"
62 #include "net/test/embedded_test_server/embedded_test_server.h" 62 #include "net/test/embedded_test_server/embedded_test_server.h"
63 #include "ui/display/display_switches.h" 63 #include "ui/display/display_switches.h"
64 64
65 #if defined(OS_MACOSX) 65 #if defined(OS_MACOSX)
66 #include "base/mac/scoped_nsautorelease_pool.h" 66 #include "base/mac/scoped_nsautorelease_pool.h"
67 #include "chrome/test/base/scoped_bundle_swizzler_mac.h" 67 #include "chrome/test/base/scoped_bundle_swizzler_mac.h"
68 #include "ui/base/test/scoped_fake_full_keyboard_access.h"
68 #endif 69 #endif
69 70
70 #if defined(OS_WIN) 71 #if defined(OS_WIN)
71 #include "base/win/scoped_com_initializer.h" 72 #include "base/win/scoped_com_initializer.h"
72 #include "base/win/windows_version.h" 73 #include "base/win/windows_version.h"
73 #include "ui/base/win/atl_module.h" 74 #include "ui/base/win/atl_module.h"
74 #endif 75 #endif
75 76
76 #if BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION) 77 #if BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION)
77 #include "chrome/browser/captive_portal/captive_portal_service.h" 78 #include "chrome/browser/captive_portal/captive_portal_service.h"
(...skipping 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
256 // which is chromeos specific feature. 257 // which is chromeos specific feature.
257 options::BrowserOptionsHandler::DisablePolymerPreloadForTesting(); 258 options::BrowserOptionsHandler::DisablePolymerPreloadForTesting();
258 #endif // defined(OS_CHROMEOS) 259 #endif // defined(OS_CHROMEOS)
259 260
260 // Use hardcoded quota settings to have a consistent testing environment. 261 // Use hardcoded quota settings to have a consistent testing environment.
261 const int kQuota = 5 * 1024 * 1024; 262 const int kQuota = 5 * 1024 * 1024;
262 quota_settings_ = storage::QuotaSettings(kQuota * 5, kQuota, 0, 0); 263 quota_settings_ = storage::QuotaSettings(kQuota * 5, kQuota, 0, 0);
263 ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting( 264 ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting(
264 &quota_settings_); 265 &quota_settings_);
265 266
267 #if defined(OS_MACOSX)
268 faked_full_keyboard_access_.reset(
269 new ui::test::ScopedFakeFullKeyboardAccess());
270 #endif // defined(OS_MACOSX)
271
266 BrowserTestBase::SetUp(); 272 BrowserTestBase::SetUp();
267 } 273 }
268 274
269 void InProcessBrowserTest::SetUpDefaultCommandLine( 275 void InProcessBrowserTest::SetUpDefaultCommandLine(
270 base::CommandLine* command_line) { 276 base::CommandLine* command_line) {
271 // Propagate commandline settings from test_launcher_utils. 277 // Propagate commandline settings from test_launcher_utils.
272 test_launcher_utils::PrepareBrowserCommandLineForTests(command_line); 278 test_launcher_utils::PrepareBrowserCommandLineForTests(command_line);
273 279
274 // This is a Browser test. 280 // This is a Browser test.
275 command_line->AppendSwitchASCII(switches::kTestType, kBrowserTestType); 281 command_line->AppendSwitchASCII(switches::kTestType, kBrowserTestType);
(...skipping 346 matching lines...) Expand 10 before | Expand all | Expand 10 after
622 // On the Mac, this eventually reaches 628 // On the Mac, this eventually reaches
623 // -[BrowserWindowController windowWillClose:], which will post a deferred 629 // -[BrowserWindowController windowWillClose:], which will post a deferred
624 // -autorelease on itself to ultimately destroy the Browser object. The line 630 // -autorelease on itself to ultimately destroy the Browser object. The line
625 // below is necessary to pump these pending messages to ensure all Browsers 631 // below is necessary to pump these pending messages to ensure all Browsers
626 // get deleted. 632 // get deleted.
627 content::RunAllPendingInMessageLoop(); 633 content::RunAllPendingInMessageLoop();
628 delete autorelease_pool_; 634 delete autorelease_pool_;
629 autorelease_pool_ = NULL; 635 autorelease_pool_ = NULL;
630 #endif 636 #endif
631 } 637 }
OLDNEW
« chrome/test/base/in_process_browser_test.h ('K') | « chrome/test/base/in_process_browser_test.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698