Merge "Remove service before adding test mock." into tm-dev

This commit is contained in:
Kweku Adams
2022-03-09 18:40:57 +00:00
committed by Android (Google) Code Review

View File

@@ -489,6 +489,7 @@ public class AppStandbyControllerTests {
@Before
public void setUp() throws Exception {
LocalServices.removeServiceForTest(UsageStatsManagerInternal.class);
LocalServices.addService(
UsageStatsManagerInternal.class, mock(UsageStatsManagerInternal.class));
MyContextWrapper myContext = new MyContextWrapper(InstrumentationRegistry.getContext());