Duty Cycling control is one of the Android-P features. In Android-P the feature will be controlled via a Developer Options button with no public API. This CL adds the button and connect it to be read via the GnssLocationProivder to control the feature. Also Roboelectric test added. Bug: 64009176 Test: Tested on Android-P build and works as expected. Also Robolectric test added. Change-Id: Icc0d259719cf9034caf2c78c790b914ab4292597
Running Settings Robolectric tests
The full suite
$ croot
$ make RunSettingsRoboTests
Running a single test class
$ croot
$ make RunSettingsRoboTests ROBOTEST_FILTER=<ClassName>
For example:
make RunSettingsRoboTests ROBOTEST_FILTER=CodeInspectionTest
You can also use partial class name in ROBOTEST_FILTER. If the partial class name matches multiple file names, all of them will be executed.