- WarningFramePreference & warning_frame_preference.xml is a battery customized layout which looks like a standard Preference layout with an optional app icon & warning chip. - PowerGaugePreference extends the WarningFramePreference to display the app Preference with optional warning chip in Battery > Battery Usage. - PowerUsageTimePreference extends the WarningFramePreference to display the usage time with optional warning chip in Battery > Battery Usage > App battery usage. Bug: 349652542 Test: atest BatteryUsageBreakdownControllerTest PowerGaugePreferenceTest PowerUsageTimeControllerTest Flag: com.android.settingslib.widget.theme.flags.is_expressive_design_enabled Change-Id: I5d22703ccc487c54a2bbbc1d9737b92a2de54ba5
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