Chromium Code Reviews| Index: chrome/browser/chromeos/system/tray_accessibility_browsertest.cc |
| diff --git a/chrome/browser/chromeos/system/tray_accessibility_browsertest.cc b/chrome/browser/chromeos/system/tray_accessibility_browsertest.cc |
| index 2350790ddfcd6d018f377ecb4bfd1287e9330b59..81ff7e2e6109cfed05930541f78a7cf6f65bfe77 100644 |
| --- a/chrome/browser/chromeos/system/tray_accessibility_browsertest.cc |
| +++ b/chrome/browser/chromeos/system/tray_accessibility_browsertest.cc |
| @@ -22,6 +22,7 @@ |
| #include "chrome/browser/extensions/api/braille_display_private/mock_braille_controller.h" |
| #include "chrome/browser/profiles/profile.h" |
| #include "chrome/browser/profiles/profile_manager.h" |
| +#include "chrome/browser/ui/ash/session_controller_client.h" |
| #include "chrome/common/chrome_switches.h" |
| #include "chrome/common/pref_names.h" |
| #include "chrome/test/base/in_process_browser_test.h" |
| @@ -146,7 +147,12 @@ class TrayAccessibilityTest |
| tray()->UpdateAfterLoginStatusChange(status); |
| } |
| - ash::LoginStatus GetLoginStatus() { return tray()->login_; } |
| + ash::LoginStatus GetLoginStatus() { |
| + // Flush to ensure the session state reaches ash and updates login status. |
| + SessionControllerClient::FlushForTesting(); |
|
James Cook
2017/04/05 00:16:24
Can this be done just when the state is changed? I
xiyuan
2017/04/05 22:29:07
Moved this to where we call SessionStarted(). Done
|
| + |
| + return tray()->login_; |
| + } |
| bool CreateDetailedMenu() { |
| tray()->ShowDetailedView(0, false); |