| OLD | NEW |
| 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 <stddef.h> | 5 #include <stddef.h> |
| 6 | 6 |
| 7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 #include "base/message_loop/message_loop.h" | 9 #include "base/message_loop/message_loop.h" |
| 10 #include "build/build_config.h" | 10 #include "build/build_config.h" |
| (...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 52 }; | 52 }; |
| 53 | 53 |
| 54 #if defined(OS_WIN) || (defined(OS_MACOSX) && defined(ADDRESS_SANITIZER)) | 54 #if defined(OS_WIN) || (defined(OS_MACOSX) && defined(ADDRESS_SANITIZER)) |
| 55 // SignOut is flaky on Windows, crbug.com/357329, | 55 // SignOut is flaky on Windows, crbug.com/357329, |
| 56 // and Mac with ASAN, crbug.com/674497. | 56 // and Mac with ASAN, crbug.com/674497. |
| 57 #define MAYBE_SignOut DISABLED_SignOut | 57 #define MAYBE_SignOut DISABLED_SignOut |
| 58 #elif defined(OS_CHROMEOS) | 58 #elif defined(OS_CHROMEOS) |
| 59 // This test doesn't make sense for Chrome OS since it has a different | 59 // This test doesn't make sense for Chrome OS since it has a different |
| 60 // multi-profiles menu in the system tray instead. | 60 // multi-profiles menu in the system tray instead. |
| 61 #define MAYBE_SignOut DISABLED_SignOut | 61 #define MAYBE_SignOut DISABLED_SignOut |
| 62 #elif defined(OS_LINUX) |
| 63 // Flaky on Linux debug builds with libc++ (https://crbug.com/734875) |
| 64 #define MAYBE_SignOut DISABLED_SignOut |
| 62 #else | 65 #else |
| 63 #define MAYBE_SignOut SignOut | 66 #define MAYBE_SignOut SignOut |
| 64 #endif | 67 #endif |
| 65 IN_PROC_BROWSER_TEST_F(ProfileListDesktopBrowserTest, MAYBE_SignOut) { | 68 IN_PROC_BROWSER_TEST_F(ProfileListDesktopBrowserTest, MAYBE_SignOut) { |
| 66 if (!profiles::IsMultipleProfilesEnabled()) | 69 if (!profiles::IsMultipleProfilesEnabled()) |
| 67 return; | 70 return; |
| 68 | 71 |
| 69 ProfileManager* profile_manager = g_browser_process->profile_manager(); | 72 ProfileManager* profile_manager = g_browser_process->profile_manager(); |
| 70 Profile* current_profile = browser()->profile(); | 73 Profile* current_profile = browser()->profile(); |
| 71 ProfileAttributesStorage& storage = | 74 ProfileAttributesStorage& storage = |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 140 false, ProfileMetrics::SWITCH_PROFILE_ICON); | 143 false, ProfileMetrics::SWITCH_PROFILE_ICON); |
| 141 EXPECT_EQ(2u, browser_list->size()); | 144 EXPECT_EQ(2u, browser_list->size()); |
| 142 | 145 |
| 143 // Switch to the first profile without opening a new window. | 146 // Switch to the first profile without opening a new window. |
| 144 menu->SwitchToProfile(menu->GetIndexOfItemWithProfilePath(path_profile1), | 147 menu->SwitchToProfile(menu->GetIndexOfItemWithProfilePath(path_profile1), |
| 145 false, ProfileMetrics::SWITCH_PROFILE_ICON); | 148 false, ProfileMetrics::SWITCH_PROFILE_ICON); |
| 146 EXPECT_EQ(2u, browser_list->size()); | 149 EXPECT_EQ(2u, browser_list->size()); |
| 147 EXPECT_EQ(path_profile1, browser_list->get(0)->profile()->GetPath()); | 150 EXPECT_EQ(path_profile1, browser_list->get(0)->profile()->GetPath()); |
| 148 EXPECT_EQ(path_profile2, browser_list->get(1)->profile()->GetPath()); | 151 EXPECT_EQ(path_profile2, browser_list->get(1)->profile()->GetPath()); |
| 149 } | 152 } |
| OLD | NEW |