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

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

Issue 10912070: Makes it possible to run content_browsertests with --as-browser and fake WebRTC devices. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Removed accidently added files. Created 8 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
« no previous file with comments | « chrome/test/base/chrome_test_suite.cc ('k') | content/public/test/test_launcher.h » ('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/file_path.h" 10 #include "base/file_path.h"
(...skipping 274 matching lines...) Expand 10 before | Expand all | Expand 10 after
285 } 285 }
286 286
287 #if !defined(OS_MACOSX) 287 #if !defined(OS_MACOSX)
288 CommandLine InProcessBrowserTest::GetCommandLineForRelaunch() { 288 CommandLine InProcessBrowserTest::GetCommandLineForRelaunch() {
289 CommandLine new_command_line(CommandLine::ForCurrentProcess()->GetProgram()); 289 CommandLine new_command_line(CommandLine::ForCurrentProcess()->GetProgram());
290 CommandLine::SwitchMap switches = 290 CommandLine::SwitchMap switches =
291 CommandLine::ForCurrentProcess()->GetSwitches(); 291 CommandLine::ForCurrentProcess()->GetSwitches();
292 switches.erase(switches::kUserDataDir); 292 switches.erase(switches::kUserDataDir);
293 switches.erase(test_launcher::kSingleProcessTestsFlag); 293 switches.erase(test_launcher::kSingleProcessTestsFlag);
294 switches.erase(test_launcher::kSingleProcessTestsAndChromeFlag); 294 switches.erase(test_launcher::kSingleProcessTestsAndChromeFlag);
295 new_command_line.AppendSwitch(ChromeTestSuite::kLaunchAsBrowser); 295 new_command_line.AppendSwitch(test_launcher::kLaunchAsBrowser);
296 296
297 #if defined(USE_AURA) 297 #if defined(USE_AURA)
298 // Copy what UITestBase::SetLaunchSwitches() does, and also what 298 // Copy what UITestBase::SetLaunchSwitches() does, and also what
299 // ChromeTestSuite does if the process had went into the test path. Otherwise 299 // ChromeTestSuite does if the process had went into the test path. Otherwise
300 // tests will fail on bots. 300 // tests will fail on bots.
301 if (!CommandLine::ForCurrentProcess()->HasSwitch( 301 if (!CommandLine::ForCurrentProcess()->HasSwitch(
302 switches::kDisableTestCompositor)) { 302 switches::kDisableTestCompositor)) {
303 new_command_line.AppendSwitch(switches::kTestCompositor); 303 new_command_line.AppendSwitch(switches::kTestCompositor);
304 } 304 }
305 #endif 305 #endif
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
380 // On the Mac, this eventually reaches 380 // On the Mac, this eventually reaches
381 // -[BrowserWindowController windowWillClose:], which will post a deferred 381 // -[BrowserWindowController windowWillClose:], which will post a deferred
382 // -autorelease on itself to ultimately destroy the Browser object. The line 382 // -autorelease on itself to ultimately destroy the Browser object. The line
383 // below is necessary to pump these pending messages to ensure all Browsers 383 // below is necessary to pump these pending messages to ensure all Browsers
384 // get deleted. 384 // get deleted.
385 content::RunAllPendingInMessageLoop(); 385 content::RunAllPendingInMessageLoop();
386 delete autorelease_pool_; 386 delete autorelease_pool_;
387 autorelease_pool_ = NULL; 387 autorelease_pool_ = NULL;
388 #endif 388 #endif
389 } 389 }
OLDNEW
« no previous file with comments | « chrome/test/base/chrome_test_suite.cc ('k') | content/public/test/test_launcher.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698