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

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

Issue 1794353003: Refactor ProfileInfoCache in c/b/profiles (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix a bug that causes unit tests without debug code to fail. Created 4 years, 8 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
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 #include <stddef.h> 6 #include <stddef.h>
7 7
8 #include "base/base_paths.h" 8 #include "base/base_paths.h"
9 #include "base/files/file_util.h" 9 #include "base/files/file_util.h"
10 #include "base/location.h" 10 #include "base/location.h"
11 #include "base/message_loop/message_loop.h" 11 #include "base/message_loop/message_loop.h"
12 #include "base/path_service.h" 12 #include "base/path_service.h"
13 #include "base/strings/string16.h" 13 #include "base/strings/string16.h"
14 #include "base/test/scoped_path_override.h" 14 #include "base/test/scoped_path_override.h"
15 #include "base/test/test_shortcut_win.h" 15 #include "base/test/test_shortcut_win.h"
16 #include "base/win/shortcut.h" 16 #include "base/win/shortcut.h"
17 #include "chrome/browser/profiles/profile.h" 17 #include "chrome/browser/profiles/profile.h"
18 #include "chrome/browser/profiles/profile_info_cache.h"
18 #include "chrome/browser/profiles/profile_manager.h" 19 #include "chrome/browser/profiles/profile_manager.h"
19 #include "chrome/browser/profiles/profile_shortcut_manager.h" 20 #include "chrome/browser/profiles/profile_shortcut_manager.h"
20 #include "chrome/browser/profiles/profile_shortcut_manager_win.h" 21 #include "chrome/browser/profiles/profile_shortcut_manager_win.h"
21 #include "chrome/browser/shell_integration_win.h" 22 #include "chrome/browser/shell_integration_win.h"
22 #include "chrome/grit/chromium_strings.h" 23 #include "chrome/grit/chromium_strings.h"
23 #include "chrome/installer/util/browser_distribution.h" 24 #include "chrome/installer/util/browser_distribution.h"
24 #include "chrome/installer/util/product.h" 25 #include "chrome/installer/util/product.h"
25 #include "chrome/installer/util/shell_util.h" 26 #include "chrome/installer/util/shell_util.h"
26 #include "chrome/test/base/testing_browser_process.h" 27 #include "chrome/test/base/testing_browser_process.h"
27 #include "chrome/test/base/testing_profile.h" 28 #include "chrome/test/base/testing_profile.h"
(...skipping 1003 matching lines...) Expand 10 before | Expand all | Expand 10 after
1031 GetDefaultShortcutPathForProfile(profile_2_name_))); 1032 GetDefaultShortcutPathForProfile(profile_2_name_)));
1032 EXPECT_TRUE(base::PathExists(profile_3_shortcut_path)); 1033 EXPECT_TRUE(base::PathExists(profile_3_shortcut_path));
1033 profile_info_cache_->DeleteProfileFromCache(profile_2_path_); 1034 profile_info_cache_->DeleteProfileFromCache(profile_2_path_);
1034 RunPendingTasks(); 1035 RunPendingTasks();
1035 EXPECT_FALSE(base::PathExists( 1036 EXPECT_FALSE(base::PathExists(
1036 GetDefaultShortcutPathForProfile(profile_2_name_))); 1037 GetDefaultShortcutPathForProfile(profile_2_name_)));
1037 // Only profile3 exists. There should be non-profile shortcut only. 1038 // Only profile3 exists. There should be non-profile shortcut only.
1038 EXPECT_FALSE(base::PathExists(profile_3_shortcut_path)); 1039 EXPECT_FALSE(base::PathExists(profile_3_shortcut_path));
1039 ValidateNonProfileShortcut(FROM_HERE); 1040 ValidateNonProfileShortcut(FROM_HERE);
1040 } 1041 }
OLDNEW
« no previous file with comments | « chrome/browser/profiles/profile_shortcut_manager.h ('k') | chrome/browser/profiles/profile_shortcut_manager_win.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698