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

Side by Side Diff: chrome/browser/profiles/profile_shortcut_manager_unittest_win.cc

Issue 16943003: Rewrite scoped_ptr<T>(NULL) to use the default ctor. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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 | « no previous file | chrome_frame/urlmon_bind_status_callback.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 <objbase.h> // For CoInitialize(). 5 #include <objbase.h> // For CoInitialize().
6 6
7 #include "base/base_paths.h" 7 #include "base/base_paths.h"
8 #include "base/file_util.h" 8 #include "base/file_util.h"
9 #include "base/location.h" 9 #include "base/location.h"
10 #include "base/message_loop.h" 10 #include "base/message_loop.h"
(...skipping 18 matching lines...) Expand all
29 #include "testing/gtest/include/gtest/gtest.h" 29 #include "testing/gtest/include/gtest/gtest.h"
30 #include "ui/base/l10n/l10n_util.h" 30 #include "ui/base/l10n/l10n_util.h"
31 31
32 using content::BrowserThread; 32 using content::BrowserThread;
33 33
34 class ProfileShortcutManagerTest : public testing::Test { 34 class ProfileShortcutManagerTest : public testing::Test {
35 protected: 35 protected:
36 ProfileShortcutManagerTest() 36 ProfileShortcutManagerTest()
37 : ui_thread_(BrowserThread::UI, &message_loop_), 37 : ui_thread_(BrowserThread::UI, &message_loop_),
38 file_thread_(BrowserThread::FILE, &message_loop_), 38 file_thread_(BrowserThread::FILE, &message_loop_),
39 profile_shortcut_manager_(NULL),
40 profile_info_cache_(NULL), 39 profile_info_cache_(NULL),
41 fake_user_desktop_(base::DIR_USER_DESKTOP), 40 fake_user_desktop_(base::DIR_USER_DESKTOP),
42 fake_system_desktop_(base::DIR_COMMON_DESKTOP) { 41 fake_system_desktop_(base::DIR_COMMON_DESKTOP) {
43 } 42 }
44 43
45 virtual void SetUp() OVERRIDE { 44 virtual void SetUp() OVERRIDE {
46 CoInitialize(NULL); 45 CoInitialize(NULL);
47 46
48 TestingBrowserProcess* browser_process = 47 TestingBrowserProcess* browser_process =
49 TestingBrowserProcess::GetGlobal(); 48 TestingBrowserProcess::GetGlobal();
(...skipping 716 matching lines...) Expand 10 before | Expand all | Expand 10 after
766 profile_info_cache_->DeleteProfileFromCache(profile_2_path_); 765 profile_info_cache_->DeleteProfileFromCache(profile_2_path_);
767 RunPendingTasks(); 766 RunPendingTasks();
768 767
769 // Verify that only the system-level shortcut still exists. 768 // Verify that only the system-level shortcut still exists.
770 EXPECT_TRUE(file_util::PathExists(system_level_shortcut_path)); 769 EXPECT_TRUE(file_util::PathExists(system_level_shortcut_path));
771 EXPECT_FALSE(file_util::PathExists( 770 EXPECT_FALSE(file_util::PathExists(
772 GetDefaultShortcutPathForProfile(string16()))); 771 GetDefaultShortcutPathForProfile(string16())));
773 EXPECT_FALSE(file_util::PathExists(profile_1_shortcut_path)); 772 EXPECT_FALSE(file_util::PathExists(profile_1_shortcut_path));
774 EXPECT_FALSE(file_util::PathExists(profile_2_shortcut_path)); 773 EXPECT_FALSE(file_util::PathExists(profile_2_shortcut_path));
775 } 774 }
OLDNEW
« no previous file with comments | « no previous file | chrome_frame/urlmon_bind_status_callback.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698