Chromium Code Reviews| Index: ash/common/system/update/tray_update_unittest.cc |
| diff --git a/ash/common/system/update/tray_update_unittest.cc b/ash/common/system/update/tray_update_unittest.cc |
| index 1c6c796dbfaa3752e9b15abfa97b42957a32b0de..6aa8f1b4b02da9cad1e5140b34665fc602c3b57c 100644 |
| --- a/ash/common/system/update/tray_update_unittest.cc |
| +++ b/ash/common/system/update/tray_update_unittest.cc |
| @@ -5,10 +5,10 @@ |
| #include "ash/common/system/update/tray_update.h" |
| #include "ash/common/system/tray/system_tray.h" |
| -#include "ash/common/system/tray/system_tray_delegate.h" |
| -#include "ash/common/system/tray/system_tray_notifier.h" |
| +#include "ash/common/system/tray/system_tray_controller.h" |
| #include "ash/common/test/ash_test.h" |
| #include "ash/common/wm_shell.h" |
| +#include "ash/public/interfaces/update.mojom.h" |
| namespace ash { |
| @@ -19,18 +19,12 @@ using TrayUpdateTest = AshTest; |
| TEST_F(TrayUpdateTest, VisibilityAfterUpdate) { |
| TrayUpdate* tray_update = GetPrimarySystemTray()->GetTrayUpdateForTesting(); |
| - // The system starts with no update pending. |
| - UpdateInfo initial_info; |
| - WmShell::Get()->system_tray_delegate()->GetSystemUpdateInfo(&initial_info); |
| - EXPECT_FALSE(initial_info.update_required); |
| - |
| - // When no update is pending, the item isn't visible. |
| + // The system starts with no update pending, so the icon isn't visible. |
| EXPECT_FALSE(tray_update->tray_view()->visible()); |
| // Simulate an update. |
| - UpdateInfo info; |
| - info.update_required = true; |
| - WmShell::Get()->system_tray_notifier()->NotifyUpdateRecommended(info); |
| + WmShell::Get()->system_tray_controller()->ShowUpdateIcon( |
|
James Cook
2016/12/09 22:34:13
I decided to test this at the SystemTrayController
msw
2016/12/09 23:41:51
Acknowledged.
|
| + mojom::UpdateSeverity::LOW, false); |
| // Tray item is now visible. |
| EXPECT_TRUE(tray_update->tray_view()->visible()); |