DeviceStateMonitor and unit test polish
DeviceStateMonitorTest has @FlakyTest cases which get undetermistic result when test in different context. This CL remove those flakiness by - Initializing all states to off to have a determistic starting point. - Reseting mSimulatedCommandsVerifier to eliminate the accumuated impact of Mockito.verify() on the follow test cases. This CL also - Add missing debug info of log and dumpstate for DeviceStateMonitor. - Add more test cases to cover more methods. - Clear up unused fields and comments for DeviceStateMonitor. - Remove hard-codes with constants in DeviceStateMonitorTest. - Pass all test cases in both Cuttlefish and Pixel3 phone. Bug: 149223121 Test: atest DeviceStateMonitorTest Change-Id: I987407ef812c83b10b84ba59c1f4010a0d27c143
Loading
Please register or sign in to comment