Helper function composed to return thread future, to guarantee concurrent function finishes before test condition is checked. Additionally a @VisibleForTesting helper function is used rather than robolectric reflection helpers to set a class variable. Test: atest -c TopLevelStoragePreferenceControllerTest Change-Id: Ia22ebac4baec60f72b8516e9e79998cd788266ab
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.