In controller test, simulating profile with hideIndQuietMode set to true in by mocking AppEntry is not possible. updateAppList() method is assumed to already receive a filtered list of apps based on the profile's quiet mode status which is called from onRebuildComplete(). Corresponding filters for this page has test in the underlying settingsLib ApplicationsStateTest file Bug: 26013153 Test: Manual Flag: EXEMPT only test file Change-Id: I09ea3b279c40e0ee4806a80646a5dfcd3d3f784b
Running Settings Robolectric tests
The full suite
$ croot
$ atest SettingsRoboTests
Running a single test class
With a filter
$ croot
$ atest SettingsRoboTests:com.android.settings.display.AdaptiveSleepPreferenceControllerTest
You can also run any single test class with atest (it will try to find the correct path)
$ atest AdaptiveSleepPreferenceControllerTest