### Question:
PasswordGeneratorService { @VisibleForTesting static boolean passesAzureCharacterRules(String s) { return LETTERS.matcher(s).find() && DIGITS.matcher(s).find(); }  String generatePassword(Optional<CloudPlatform> cloudPlatform);  }### Answer:
@Test public void testPassesAzureCharacterRules() { assertTrue(PasswordGeneratorService.passesAzureCharacterRules("Aa1")); assertTrue(PasswordGeneratorService.passesAzureCharacterRules("aa1")); assertTrue(PasswordGeneratorService.passesAzureCharacterRules("AA1")); assertFalse(PasswordGeneratorService.passesAzureCharacterRules("AaA")); assertFalse(PasswordGeneratorService.passesAzureCharacterRules("111")); assertFalse(PasswordGeneratorService.passesAzureCharacterRules("AAA")); assertFalse(PasswordGeneratorService.passesAzureCharacterRules("aaa")); assertFalse(PasswordGeneratorService.passesAzureCharacterRules("---")); }