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

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

Issue 2405013002: Move some global feature defines to buildflags (Closed)
Patch Set: Comment Created 4 years, 2 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
« no previous file with comments | « chrome/renderer/plugins/chrome_plugin_placeholder.cc ('k') | tools/grit/grit_rule.gni » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 23 matching lines...) Expand all
34 #include "chrome/browser/ui/browser_list.h" 34 #include "chrome/browser/ui/browser_list.h"
35 #include "chrome/browser/ui/browser_list_observer.h" 35 #include "chrome/browser/ui/browser_list_observer.h"
36 #include "chrome/browser/ui/browser_navigator.h" 36 #include "chrome/browser/ui/browser_navigator.h"
37 #include "chrome/browser/ui/browser_navigator_params.h" 37 #include "chrome/browser/ui/browser_navigator_params.h"
38 #include "chrome/browser/ui/browser_tabstrip.h" 38 #include "chrome/browser/ui/browser_tabstrip.h"
39 #include "chrome/browser/ui/browser_window.h" 39 #include "chrome/browser/ui/browser_window.h"
40 #include "chrome/browser/ui/tabs/tab_strip_model.h" 40 #include "chrome/browser/ui/tabs/tab_strip_model.h"
41 #include "chrome/common/chrome_constants.h" 41 #include "chrome/common/chrome_constants.h"
42 #include "chrome/common/chrome_paths.h" 42 #include "chrome/common/chrome_paths.h"
43 #include "chrome/common/chrome_switches.h" 43 #include "chrome/common/chrome_switches.h"
44 #include "chrome/common/features.h"
44 #include "chrome/common/logging_chrome.h" 45 #include "chrome/common/logging_chrome.h"
45 #include "chrome/common/url_constants.h" 46 #include "chrome/common/url_constants.h"
46 #include "chrome/renderer/chrome_content_renderer_client.h" 47 #include "chrome/renderer/chrome_content_renderer_client.h"
47 #include "chrome/test/base/chrome_test_suite.h" 48 #include "chrome/test/base/chrome_test_suite.h"
48 #include "chrome/test/base/test_launcher_utils.h" 49 #include "chrome/test/base/test_launcher_utils.h"
49 #include "chrome/test/base/testing_browser_process.h" 50 #include "chrome/test/base/testing_browser_process.h"
50 #include "components/google/core/browser/google_util.h" 51 #include "components/google/core/browser/google_util.h"
51 #include "components/os_crypt/os_crypt_mocker.h" 52 #include "components/os_crypt/os_crypt_mocker.h"
52 #include "content/public/browser/devtools_agent_host.h" 53 #include "content/public/browser/devtools_agent_host.h"
53 #include "content/public/browser/notification_service.h" 54 #include "content/public/browser/notification_service.h"
54 #include "content/public/browser/notification_types.h" 55 #include "content/public/browser/notification_types.h"
55 #include "content/public/common/content_switches.h" 56 #include "content/public/common/content_switches.h"
56 #include "content/public/test/browser_test_utils.h" 57 #include "content/public/test/browser_test_utils.h"
57 #include "content/public/test/test_launcher.h" 58 #include "content/public/test/test_launcher.h"
58 #include "content/public/test/test_navigation_observer.h" 59 #include "content/public/test/test_navigation_observer.h"
59 #include "net/test/embedded_test_server/embedded_test_server.h" 60 #include "net/test/embedded_test_server/embedded_test_server.h"
60 #include "ui/display/display_switches.h" 61 #include "ui/display/display_switches.h"
61 62
62 #if defined(OS_MACOSX) 63 #if defined(OS_MACOSX)
63 #include "base/mac/scoped_nsautorelease_pool.h" 64 #include "base/mac/scoped_nsautorelease_pool.h"
64 #include "chrome/test/base/scoped_bundle_swizzler_mac.h" 65 #include "chrome/test/base/scoped_bundle_swizzler_mac.h"
65 #endif 66 #endif
66 67
67 #if defined(OS_WIN) 68 #if defined(OS_WIN)
68 #include "base/win/scoped_com_initializer.h" 69 #include "base/win/scoped_com_initializer.h"
69 #include "base/win/windows_version.h" 70 #include "base/win/windows_version.h"
70 #include "ui/base/win/atl_module.h" 71 #include "ui/base/win/atl_module.h"
71 #endif 72 #endif
72 73
73 #if defined(ENABLE_CAPTIVE_PORTAL_DETECTION) 74 #if BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION)
74 #include "chrome/browser/captive_portal/captive_portal_service.h" 75 #include "chrome/browser/captive_portal/captive_portal_service.h"
75 #endif 76 #endif
76 77
77 #if !defined(OS_ANDROID) 78 #if !defined(OS_ANDROID)
78 #include "components/storage_monitor/test_storage_monitor.h" 79 #include "components/storage_monitor/test_storage_monitor.h"
79 #endif 80 #endif
80 81
81 #if defined(OS_CHROMEOS) 82 #if defined(OS_CHROMEOS)
82 #include "chrome/browser/chromeos/input_method/input_method_configuration.h" 83 #include "chrome/browser/chromeos/input_method/input_method_configuration.h"
83 #endif 84 #endif
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after
230 DCHECK(!display::Screen::GetScreen()); 231 DCHECK(!display::Screen::GetScreen());
231 display::Screen::SetScreenInstance( 232 display::Screen::SetScreenInstance(
232 views::test::TestDesktopScreenX11::GetInstance()); 233 views::test::TestDesktopScreenX11::GetInstance());
233 #endif 234 #endif
234 235
235 // Always use a mocked password storage if OS encryption is used (which is 236 // Always use a mocked password storage if OS encryption is used (which is
236 // when anything sensitive gets stored, including Cookies). Without this on 237 // when anything sensitive gets stored, including Cookies). Without this on
237 // Mac, many tests will hang waiting for a user to approve KeyChain access. 238 // Mac, many tests will hang waiting for a user to approve KeyChain access.
238 OSCryptMocker::SetUpWithSingleton(); 239 OSCryptMocker::SetUpWithSingleton();
239 240
240 #if defined(ENABLE_CAPTIVE_PORTAL_DETECTION) 241 #if BUILDFLAG(ENABLE_CAPTIVE_PORTAL_DETECTION)
241 CaptivePortalService::set_state_for_testing( 242 CaptivePortalService::set_state_for_testing(
242 CaptivePortalService::DISABLED_FOR_TESTING); 243 CaptivePortalService::DISABLED_FOR_TESTING);
243 #endif 244 #endif
244 245
245 chrome_browser_net::NetErrorTabHelper::set_state_for_testing( 246 chrome_browser_net::NetErrorTabHelper::set_state_for_testing(
246 chrome_browser_net::NetErrorTabHelper::TESTING_FORCE_DISABLED); 247 chrome_browser_net::NetErrorTabHelper::TESTING_FORCE_DISABLED);
247 248
248 google_util::SetMockLinkDoctorBaseURLForTesting(); 249 google_util::SetMockLinkDoctorBaseURLForTesting();
249 250
250 BrowserTestBase::SetUp(); 251 BrowserTestBase::SetUp();
(...skipping 355 matching lines...) Expand 10 before | Expand all | Expand 10 after
606 // On the Mac, this eventually reaches 607 // On the Mac, this eventually reaches
607 // -[BrowserWindowController windowWillClose:], which will post a deferred 608 // -[BrowserWindowController windowWillClose:], which will post a deferred
608 // -autorelease on itself to ultimately destroy the Browser object. The line 609 // -autorelease on itself to ultimately destroy the Browser object. The line
609 // below is necessary to pump these pending messages to ensure all Browsers 610 // below is necessary to pump these pending messages to ensure all Browsers
610 // get deleted. 611 // get deleted.
611 content::RunAllPendingInMessageLoop(); 612 content::RunAllPendingInMessageLoop();
612 delete autorelease_pool_; 613 delete autorelease_pool_;
613 autorelease_pool_ = NULL; 614 autorelease_pool_ = NULL;
614 #endif 615 #endif
615 } 616 }
OLDNEW
« no previous file with comments | « chrome/renderer/plugins/chrome_plugin_placeholder.cc ('k') | tools/grit/grit_rule.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698