Fix bubble tests for things that don't have face service
Bug: 135475155
Test: atest BubbleControllerTest
Change-Id: Ib6c3c8175d7ad9d5ecba96923bbfa0e90916f0da
diff --git a/packages/SystemUI/tests/src/com/android/systemui/bubbles/BubbleControllerTest.java b/packages/SystemUI/tests/src/com/android/systemui/bubbles/BubbleControllerTest.java
index fa7aa50..cf1e5fb 100644
--- a/packages/SystemUI/tests/src/com/android/systemui/bubbles/BubbleControllerTest.java
+++ b/packages/SystemUI/tests/src/com/android/systemui/bubbles/BubbleControllerTest.java
@@ -47,6 +47,7 @@
import android.content.Intent;
import android.content.IntentFilter;
import android.graphics.drawable.Icon;
+import android.hardware.face.FaceManager;
import android.service.notification.ZenModeConfig;
import android.testing.AndroidTestingRunner;
import android.testing.TestableLooper;
@@ -106,6 +107,8 @@
private ZenModeController mZenModeController;
@Mock
private ZenModeConfig mZenModeConfig;
+ @Mock
+ private FaceManager mFaceManager;
private FrameLayout mStatusBarView;
@Captor
@@ -141,6 +144,7 @@
MockitoAnnotations.initMocks(this);
mStatusBarView = new FrameLayout(mContext);
mDependency.injectTestDependency(NotificationEntryManager.class, mNotificationEntryManager);
+ mContext.addMockSystemService(FaceManager.class, mFaceManager);
// Bubbles get added to status bar window view
mStatusBarWindowController = new StatusBarWindowController(mContext, mWindowManager,