Adds a new param about the charging policy to see if it's currently under CHARGING_POLICY_ADAPTIVE_LONGLIFE for more flexibility to check whether the charging optimization mode is enabled. Bug: 391270019 Flag: EXEMPT bugfix Test: atest SettingsRoboTests Change-Id: Ie773d9a2a13d1a37ac9fd5940f10a100eccf77ca
Running Settings Robolectric tests
The full suite
$ croot
$ atest SettingsRoboTests
Running a single test class
With a filter
$ croot
$ atest SettingsRoboTests:com.android.settings.display.AdaptiveSleepPreferenceControllerTest
You can also run any single test class with atest (it will try to find the correct path)
$ atest AdaptiveSleepPreferenceControllerTest