1. The carrier or privileged apps will enable/disable network types on the device, so Settings references the allowed network type to show/hide 5G preferred network type option. 2. For mainline, copy the getNetworkTypeFromRaf() from RadioFamily to Settings. Bug: 136730709 Test: Manual test & EnabledNetworkModePreferenceControllerTest 1. Enable allowed_network_type 2. Disable allowed_network_type Merged-In: I493f2a2c7f4bc32b3fcb8ab2bace5839d8667bd5 Change-Id: Id591f454a60d0ba08c3fc4a2ffe40836dafeb5f0
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.