Most logic is copied from previous ListPreference however 1. Create PreferenceController for it 2. Extract API to check whether to display CMDA options 3. In controller, provide API to force display dialog Bug: 114749736 Test: RunSettingsRoboTests Change-Id: Ic40d2ac1dc1854df9c90d912ea9fc822531b413d
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.