| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "chrome/browser/ui/ash/system_tray_delegate_chromeos.h" | 5 #include "chrome/browser/ui/ash/system_tray_delegate_chromeos.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "ash/display/display_manager.h" | 9 #include "ash/display/display_manager.h" |
| 10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 76 } | 76 } |
| 77 }; | 77 }; |
| 78 | 78 |
| 79 class SystemTrayDelegateChromeOSTest : public LoginManagerTest { | 79 class SystemTrayDelegateChromeOSTest : public LoginManagerTest { |
| 80 protected: | 80 protected: |
| 81 SystemTrayDelegateChromeOSTest() | 81 SystemTrayDelegateChromeOSTest() |
| 82 : LoginManagerTest(false /* should_launch_browser */) {} | 82 : LoginManagerTest(false /* should_launch_browser */) {} |
| 83 | 83 |
| 84 ~SystemTrayDelegateChromeOSTest() override {} | 84 ~SystemTrayDelegateChromeOSTest() override {} |
| 85 | 85 |
| 86 void SetupUserProfile(std::string user_name, bool use_24_hour_clock) { | 86 void SetupUserProfile(const std::string& user_name, bool use_24_hour_clock) { |
| 87 const user_manager::User* user = | 87 const user_manager::User* user = |
| 88 user_manager::UserManager::Get()->FindUser(user_name); | 88 user_manager::UserManager::Get()->FindUser(user_name); |
| 89 Profile* profile = ProfileHelper::Get()->GetProfileByUser(user); | 89 Profile* profile = ProfileHelper::Get()->GetProfileByUser(user); |
| 90 profile->GetPrefs()->SetBoolean(prefs::kUse24HourClock, use_24_hour_clock); | 90 profile->GetPrefs()->SetBoolean(prefs::kUse24HourClock, use_24_hour_clock); |
| 91 } | 91 } |
| 92 | 92 |
| 93 private: | 93 private: |
| 94 DISALLOW_COPY_AND_ASSIGN(SystemTrayDelegateChromeOSTest); | 94 DISALLOW_COPY_AND_ASSIGN(SystemTrayDelegateChromeOSTest); |
| 95 }; | 95 }; |
| 96 | 96 |
| (...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 147 | 147 |
| 148 UpdateDisplay("400x400"); | 148 UpdateDisplay("400x400"); |
| 149 | 149 |
| 150 ui_test_utils::NavigateToURL(browser(), GURL("chrome://version")); | 150 ui_test_utils::NavigateToURL(browser(), GURL("chrome://version")); |
| 151 UpdateDisplay("400x400/r"); | 151 UpdateDisplay("400x400/r"); |
| 152 // Ensure that there is a notification that is shown. | 152 // Ensure that there is a notification that is shown. |
| 153 EXPECT_FALSE(GetVisibleNotifications().empty()); | 153 EXPECT_FALSE(GetVisibleNotifications().empty()); |
| 154 } | 154 } |
| 155 | 155 |
| 156 } // namespace chromeos | 156 } // namespace chromeos |
| OLD | NEW |