Currently minimum password length policy is queried twice: 1. When constructiong the intent in ChooseLockGenericFragment.getIntentForUnlockMethod and then passed into setPasswordLengthRange in getLockPasswordIntent 2. in ChooseLockPasswordFragment.processPasswordRequirements via LockPatternUtils.getRequestedMinimumPasswordLength(). These two values are then combined in processPasswordRequirements using Math.max(), which doesn't make sense since it is the same value. With this CL it is only queried once in processPasswordRequirements. + cleaned up code filling in unused list. + removed unused extras, since they are never set anywhere. Bug: 30558331 Test: atest ChooseLockPasswordTest Test: atest SetupChooseLockPasswordTest Test: atest ChooseLockGenericTest Test: manual, set password policy and change password. Change-Id: Ifc4946d5b3b26131da01178fa9c827de7a52c7c6
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.