### Question:
CannedPropertyValidators { public static BooleanPropertyValidationRules boolValidator() { return new BooleanPropertyValidationRules(); }  static BooleanPropertyValidationRules boolValidator(); static PinPropertyValidationRules pinValidator(); static PinPropertyValidationRules optPinValidator(); static IntegerPropertyValidationRules uintValidator(int max); static StringPropertyValidationRules variableValidator(); static StringPropertyValidationRules textValidator(); static ChoicesPropertyValidationRules choicesValidator(Collection<String> values); static MenuItemValidationRules menuItemValidatorForAllItems(); static MenuItemValidationRules menuItemValidatorForSpecifcType(Class<? extends MenuItem> cls);  }### Answer:
@Test public void testBooleanValidator() { BooleanPropertyValidationRules validator = CannedPropertyValidators.boolValidator(); assertTrue(validator.hasChoices()); assertThat(validator.choices()).containsExactlyInAnyOrder("true", "false"); assertTrue(validator.isValueValid("true")); assertTrue(validator.isValueValid("false")); assertFalse(validator.isValueValid("invalid")); }