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

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

Issue 280603002: Disable ProfileListDesktopBrowserTest on Chrome OS since it has different multi-profiles UI (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 7 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 | no next file » | 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) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/path_service.h" 6 #include "base/path_service.h"
7 #include "chrome/browser/chrome_notification_types.h" 7 #include "chrome/browser/chrome_notification_types.h"
8 #include "chrome/browser/profiles/avatar_menu.h" 8 #include "chrome/browser/profiles/avatar_menu.h"
9 #include "chrome/browser/profiles/profile_manager.h" 9 #include "chrome/browser/profiles/profile_manager.h"
10 #include "chrome/browser/profiles/profile_window.h" 10 #include "chrome/browser/profiles/profile_window.h"
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 browser())); 42 browser()));
43 return avatar_menu_.get(); 43 return avatar_menu_.get();
44 } 44 }
45 45
46 private: 46 private:
47 scoped_ptr<AvatarMenu> avatar_menu_; 47 scoped_ptr<AvatarMenu> avatar_menu_;
48 48
49 DISALLOW_COPY_AND_ASSIGN(ProfileListDesktopBrowserTest); 49 DISALLOW_COPY_AND_ASSIGN(ProfileListDesktopBrowserTest);
50 }; 50 };
51 51
52 #if defined (OS_WIN) 52 #if defined(OS_WIN)
53 // SignOut is flaky. So far only observed on Windows. crbug.com/357329. 53 // SignOut is flaky. So far only observed on Windows. crbug.com/357329.
54 #define MAYBE_SignOut DISABLED_SignOut 54 #define MAYBE_SignOut DISABLED_SignOut
55 #elif defined(OS_CHROMEOS)
rpetterson 2014/05/12 17:53:55 I've always seen that the disables are combined an
56 // This test doesn't make sense for Chrome OS since it has a different
57 // multi-profiles menu in the system tray instead.
58 #define MAYBE_SignOut DISABLED_SignOut
55 #else 59 #else
56 #define MAYBE_SignOut SignOut 60 #define MAYBE_SignOut SignOut
57 #endif 61 #endif
58 IN_PROC_BROWSER_TEST_F(ProfileListDesktopBrowserTest, MAYBE_SignOut) { 62 IN_PROC_BROWSER_TEST_F(ProfileListDesktopBrowserTest, MAYBE_SignOut) {
59 if (!profiles::IsMultipleProfilesEnabled()) 63 if (!profiles::IsMultipleProfilesEnabled())
60 return; 64 return;
61 65
62 ProfileManager* profile_manager = g_browser_process->profile_manager(); 66 ProfileManager* profile_manager = g_browser_process->profile_manager();
63 Profile* current_profile = browser()->profile(); 67 Profile* current_profile = browser()->profile();
64 ProfileInfoCache& cache = profile_manager->GetProfileInfoCache(); 68 ProfileInfoCache& cache = profile_manager->GetProfileInfoCache();
(...skipping 13 matching lines...) Expand all
78 profiles::LockProfile(current_profile); 82 profiles::LockProfile(current_profile);
79 window_close_observer.Wait(); // rely on test time-out for failure indication 83 window_close_observer.Wait(); // rely on test time-out for failure indication
80 84
81 EXPECT_TRUE(cache.ProfileIsSigninRequiredAtIndex(index)); 85 EXPECT_TRUE(cache.ProfileIsSigninRequiredAtIndex(index));
82 EXPECT_EQ(0U, browser_list->size()); 86 EXPECT_EQ(0U, browser_list->size());
83 87
84 // Signing out brings up the User Manager which we should close before exit. 88 // Signing out brings up the User Manager which we should close before exit.
85 chrome::HideUserManager(); 89 chrome::HideUserManager();
86 } 90 }
87 91
88 IN_PROC_BROWSER_TEST_F(ProfileListDesktopBrowserTest, SwitchToProfile) { 92 #if defined(OS_CHROMEOS)
93 // This test doesn't make sense for Chrome OS since it has a different
94 // multi-profiles menu in the system tray instead.
95 #define MAYBE_SwitchToProfile DISABLED_SwitchToProfile
96 #else
97 #define MAYBE_SwitchToProfile SwitchToProfile
98 #endif
99 IN_PROC_BROWSER_TEST_F(ProfileListDesktopBrowserTest, MAYBE_SwitchToProfile) {
89 #if defined(OS_WIN) && defined(USE_ASH) 100 #if defined(OS_WIN) && defined(USE_ASH)
90 // Disable this test in Metro+Ash for now (http://crbug.com/262796). 101 // Disable this test in Metro+Ash for now (http://crbug.com/262796).
91 if (CommandLine::ForCurrentProcess()->HasSwitch(switches::kAshBrowserTests)) 102 if (CommandLine::ForCurrentProcess()->HasSwitch(switches::kAshBrowserTests))
92 return; 103 return;
93 #endif 104 #endif
94 105
95 if (!profiles::IsMultipleProfilesEnabled()) 106 if (!profiles::IsMultipleProfilesEnabled())
96 return; 107 return;
97 108
98 ProfileManager* profile_manager = g_browser_process->profile_manager(); 109 ProfileManager* profile_manager = g_browser_process->profile_manager();
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 false, ProfileMetrics::SWITCH_PROFILE_ICON); 143 false, ProfileMetrics::SWITCH_PROFILE_ICON);
133 EXPECT_EQ(2U, browser_list->size()); 144 EXPECT_EQ(2U, browser_list->size());
134 145
135 // Switch to the first profile without opening a new window. 146 // Switch to the first profile without opening a new window.
136 menu->SwitchToProfile(cache.GetIndexOfProfileWithPath(path_profile1), 147 menu->SwitchToProfile(cache.GetIndexOfProfileWithPath(path_profile1),
137 false, ProfileMetrics::SWITCH_PROFILE_ICON); 148 false, ProfileMetrics::SWITCH_PROFILE_ICON);
138 EXPECT_EQ(2U, browser_list->size()); 149 EXPECT_EQ(2U, browser_list->size());
139 EXPECT_EQ(path_profile1, browser_list->get(0)->profile()->GetPath()); 150 EXPECT_EQ(path_profile1, browser_list->get(0)->profile()->GetPath());
140 EXPECT_EQ(path_profile2, browser_list->get(1)->profile()->GetPath()); 151 EXPECT_EQ(path_profile2, browser_list->get(1)->profile()->GetPath());
141 } 152 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698