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

Unified Diff: chrome/browser/profiles/profile_shortcut_manager_unittest_win.cc

Issue 10964007: Re-commit: Add new PathService paths for Windows' All Users Desktop and Quick Launch folders. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Windows only includes/pragma in the ifdef OS_WIN 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/download/download_util.cc ('k') | chrome/browser/shell_integration_linux.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/profiles/profile_shortcut_manager_unittest_win.cc
diff --git a/chrome/browser/profiles/profile_shortcut_manager_unittest_win.cc b/chrome/browser/profiles/profile_shortcut_manager_unittest_win.cc
index 6625964dc7c0bfc655ef1034674e81a8ff9d407e..81be1841b8defc7a113b26e80643c9b5f2751664 100644
--- a/chrome/browser/profiles/profile_shortcut_manager_unittest_win.cc
+++ b/chrome/browser/profiles/profile_shortcut_manager_unittest_win.cc
@@ -61,7 +61,12 @@ class ProfileShortcutManagerTest : public testing::Test {
file_thread_(BrowserThread::FILE, &message_loop_) {
}
- virtual void SetUp() {
+ virtual void SetUp() OVERRIDE {
+ // Mock the user's Desktop into a temp directory.
+ ASSERT_TRUE(fake_user_desktop_.CreateUniqueTempDir());
+ ASSERT_TRUE(PathService::Override(base::DIR_USER_DESKTOP,
+ fake_user_desktop_.path()));
+
TestingBrowserProcess* browser_process =
static_cast<TestingBrowserProcess*>(g_browser_process);
profile_manager_.reset(new TestingProfileManager(browser_process));
@@ -80,7 +85,7 @@ class ProfileShortcutManagerTest : public testing::Test {
second_profile_name_ = ASCIIToUTF16("My profile 2");
}
- virtual void TearDown() {
+ virtual void TearDown() OVERRIDE {
message_loop_.RunAllPending();
int num_profiles =
@@ -148,6 +153,7 @@ class ProfileShortcutManagerTest : public testing::Test {
content::TestBrowserThread ui_thread_;
content::TestBrowserThread file_thread_;
scoped_ptr<TestingProfileManager> profile_manager_;
+ ScopedTempDir fake_user_desktop_;
FilePath dest_path_;
string16 profile_name_;
FilePath second_dest_path_;
« no previous file with comments | « chrome/browser/download/download_util.cc ('k') | chrome/browser/shell_integration_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698