diff options
author | mattm@chromium.org <mattm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-03-09 03:47:46 +0000 |
---|---|---|
committer | mattm@chromium.org <mattm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-03-09 03:47:46 +0000 |
commit | 8d9cc8391f11f21f6e0f2b4c81f1bc514a6c2632 (patch) | |
tree | cd14d7d55449ff1bbea0fdefdd0e3654aa0f4213 | |
parent | c3deb9a2f5772aaea66cebd864d9e182c2870d62 (diff) | |
download | chromium_src-8d9cc8391f11f21f6e0f2b4c81f1bc514a6c2632.zip chromium_src-8d9cc8391f11f21f6e0f2b4c81f1bc514a6c2632.tar.gz chromium_src-8d9cc8391f11f21f6e0f2b4c81f1bc514a6c2632.tar.bz2 |
Revert "Launching Chrome with a user-data-dir command line switch containing a non ASCII ..."
Speculative revert to try to fix win dbg MultipartResponseUITest.SingleVisit failures.
This reverts commit r40981
TBR=tony
Review URL: http://codereview.chromium.org/707001
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@40994 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/browser/browser_uitest.cc | 42 | ||||
-rw-r--r-- | chrome/browser/renderer_host/browser_render_process_host.cc | 8 |
2 files changed, 3 insertions, 47 deletions
diff --git a/chrome/browser/browser_uitest.cc b/chrome/browser/browser_uitest.cc index fdde99d..5ceb55f 100644 --- a/chrome/browser/browser_uitest.cc +++ b/chrome/browser/browser_uitest.cc @@ -4,10 +4,8 @@ #include "app/gfx/native_widget_types.h" #include "base/file_path.h" -#include "base/file_util.h" #include "base/string_util.h" #include "base/sys_info.h" -#include "base/test/test_file_util.h" #include "base/values.h" #include "chrome/app/chrome_dll_resource.h" #include "chrome/common/chrome_switches.h" @@ -307,44 +305,4 @@ TEST_F(KioskModeTest, EnableKioskModeTest) { } #endif -#if defined(OS_WIN) -// This test verifies that Chrome can be launched with a user-data-dir path -// which contains non ASCII characters. -class LaunchBrowserWithNonAsciiUserDatadir : public UITest { -public: - void SetUp() { - PathService::Get(base::DIR_TEMP, &tmp_profile_); - tmp_profile_ = tmp_profile_.AppendASCII("tmp_profile"); - tmp_profile_ = tmp_profile_.Append(L"Test Chrome Géraldine"); - - // Create a fresh, empty copy of this directory. - file_util::Delete(tmp_profile_, true); - file_util::CreateDirectory(tmp_profile_); - - launch_arguments_.AppendSwitchWithValue(switches::kUserDataDir, - tmp_profile_.ToWStringHack()); - } - - bool LaunchAppWithProfile() { - UITest::SetUp(); - return true; - } - - void TearDown() { - UITest::TearDown(); - EXPECT_TRUE(file_util::DieFileDie(tmp_profile_, true)); - } - -public: - FilePath tmp_profile_; -}; - -TEST_F(LaunchBrowserWithNonAsciiUserDatadir, TestNonAsciiUserDataDir) { - ASSERT_TRUE(LaunchAppWithProfile()); - // Verify that the window is present. - scoped_refptr<BrowserProxy> browser(automation()->GetBrowserWindow(0)); - ASSERT_TRUE(browser.get()); -} -#endif - } // namespace diff --git a/chrome/browser/renderer_host/browser_render_process_host.cc b/chrome/browser/renderer_host/browser_render_process_host.cc index 02849ae..3d70253 100644 --- a/chrome/browser/renderer_host/browser_render_process_host.cc +++ b/chrome/browser/renderer_host/browser_render_process_host.cc @@ -470,12 +470,10 @@ void BrowserRenderProcessHost::AppendRendererCommandLine( ChildProcessHost::SetCrashReporterCommandLine(command_line); - FilePath user_data_dir = - browser_command_line.GetSwitchValuePath(switches::kUserDataDir); - + const std::string user_data_dir = + browser_command_line.GetSwitchValueASCII(switches::kUserDataDir); if (!user_data_dir.empty()) - command_line->AppendSwitchWithValue(switches::kUserDataDir, - user_data_dir.value()); + command_line->AppendSwitchWithValue(switches::kUserDataDir, user_data_dir); #if defined(OS_CHROMEOS) const std::string& profile = browser_command_line.GetSwitchValueASCII(switches::kProfile); |