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

Unified Diff: chrome/browser/sessions/session_restore_uitest.cc

Issue 18248: CommandLine API rework (Closed)
Patch Set: fixes Created 11 years, 11 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
Index: chrome/browser/sessions/session_restore_uitest.cc
diff --git a/chrome/browser/sessions/session_restore_uitest.cc b/chrome/browser/sessions/session_restore_uitest.cc
index 85bb5fd72a68541249dbc7de90628b6dac7113cd..ae8803e57ebd61dd389dc1f31b29c0cf4a3a821a 100644
--- a/chrome/browser/sessions/session_restore_uitest.cc
+++ b/chrome/browser/sessions/session_restore_uitest.cc
@@ -38,8 +38,7 @@ class SessionRestoreUITest : public UITest {
clear_profile_ = false;
- CommandLine::AppendSwitch(&launch_arguments_,
- switches::kRestoreLastSession);
+ launch_arguments_.AppendSwitch(switches::kRestoreLastSession);
UITest::SetUp();
}
@@ -283,7 +282,7 @@ TEST_F(SessionRestoreUITest, DISABLED_DontRestoreWhileIncognito) {
include_testing_id_ = false;
use_existing_browser_ = true;
clear_profile_ = false;
- CommandLine::AppendSwitch(&launch_arguments_, switches::kRestoreLastSession);
+ launch_arguments_.AppendSwitch(switches::kRestoreLastSession);
LaunchBrowser(launch_arguments_, false);
// A new window should appear;
@@ -345,9 +344,9 @@ TEST_F(SessionRestoreUITest,
include_testing_id_ = false;
use_existing_browser_ = true;
clear_profile_ = false;
- std::wstring app_launch_arguments = launch_arguments_;
- CommandLine::AppendSwitchWithValue(
- &app_launch_arguments, switches::kApp, UTF8ToWide(url2.spec()));
+ CommandLine app_launch_arguments = launch_arguments_;
+ app_launch_arguments.AppendSwitchWithValue(switches::kApp,
+ UTF8ToWide(url2.spec()));
LaunchBrowser(app_launch_arguments, false);
int window_count;
ASSERT_TRUE(automation()->WaitForWindowCountToChange(1, &window_count,
@@ -358,9 +357,8 @@ TEST_F(SessionRestoreUITest,
CloseWindow(0, 2);
// Restore it, which should bring back the first window with url1.
- std::wstring restore_launch_arguments = launch_arguments_;
- CommandLine::AppendSwitch(&restore_launch_arguments,
- switches::kRestoreLastSession);
+ CommandLine restore_launch_arguments = launch_arguments_;
+ restore_launch_arguments.AppendSwitch(switches::kRestoreLastSession);
LaunchBrowser(restore_launch_arguments, false);
ASSERT_TRUE(automation()->WaitForWindowCountToChange(1, &window_count,
action_timeout_ms()));
« no previous file with comments | « chrome/browser/search_engines/template_url_prepopulate_data.cc ('k') | chrome/browser/tab_contents/web_contents.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698