| 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 "build/build_config.h" | 10 #include "build/build_config.h" |
| 10 #include "chrome/browser/chrome_notification_types.h" | 11 #include "chrome/browser/chrome_notification_types.h" |
| 11 #include "chrome/browser/profiles/avatar_menu.h" | 12 #include "chrome/browser/profiles/avatar_menu.h" |
| 12 #include "chrome/browser/profiles/profile_attributes_entry.h" | 13 #include "chrome/browser/profiles/profile_attributes_entry.h" |
| 13 #include "chrome/browser/profiles/profile_attributes_storage.h" | 14 #include "chrome/browser/profiles/profile_attributes_storage.h" |
| 14 #include "chrome/browser/profiles/profile_manager.h" | 15 #include "chrome/browser/profiles/profile_manager.h" |
| 15 #include "chrome/browser/profiles/profile_window.h" | 16 #include "chrome/browser/profiles/profile_window.h" |
| 16 #include "chrome/browser/profiles/profiles_state.h" | 17 #include "chrome/browser/profiles/profiles_state.h" |
| 17 #include "chrome/browser/ui/browser.h" | 18 #include "chrome/browser/ui/browser.h" |
| 18 #include "chrome/browser/ui/browser_list.h" | 19 #include "chrome/browser/ui/browser_list.h" |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 139 false, ProfileMetrics::SWITCH_PROFILE_ICON); | 140 false, ProfileMetrics::SWITCH_PROFILE_ICON); |
| 140 EXPECT_EQ(2u, browser_list->size()); | 141 EXPECT_EQ(2u, browser_list->size()); |
| 141 | 142 |
| 142 // Switch to the first profile without opening a new window. | 143 // Switch to the first profile without opening a new window. |
| 143 menu->SwitchToProfile(menu->GetIndexOfItemWithProfilePath(path_profile1), | 144 menu->SwitchToProfile(menu->GetIndexOfItemWithProfilePath(path_profile1), |
| 144 false, ProfileMetrics::SWITCH_PROFILE_ICON); | 145 false, ProfileMetrics::SWITCH_PROFILE_ICON); |
| 145 EXPECT_EQ(2u, browser_list->size()); | 146 EXPECT_EQ(2u, browser_list->size()); |
| 146 EXPECT_EQ(path_profile1, browser_list->get(0)->profile()->GetPath()); | 147 EXPECT_EQ(path_profile1, browser_list->get(0)->profile()->GetPath()); |
| 147 EXPECT_EQ(path_profile2, browser_list->get(1)->profile()->GetPath()); | 148 EXPECT_EQ(path_profile2, browser_list->get(1)->profile()->GetPath()); |
| 148 } | 149 } |
| OLD | NEW |