In rare cases the SignalStrength we get for a SIM can be null, which wasn't checked for in this code. This CL adds a null check and fixes the tests so it's possible to verify the fix (one of the methods that would have crashed was being spy'd over unnecessarily). Fixes: 132570076 Test: make RunSettingsRobotests Change-Id: Ifdec24f184ee2d93e5e242eb2c20695249992fc6
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.