Issue before this CL: RemoteVolumePreferenceController only return available when it is casting, otherwise return CONDITIONALLY_UNAVAILABLE. However slice database only index available controllers and keep this cache. So remote slider won't be indexed if it is not casting at that time. As a tmp fix, this CL make controller always return available unsearchable to make it indexed by database. However only add that slice if it is casting. Bug: 130124950 Test: RunSettingsRoboTests Change-Id: I191144844d6ba7ccbe3dc1c9d19801adb978abc6
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.