ModifyPageAccessValidator extends ModifyAccessValidator { @Override public String getLabel() { return getCheckAccessGranted() ? "Modify Page" : "Cannot Modify Page"; } ModifyPageAccessValidator(Group group, Resource resource, AccessValidatorContext context, boolean checkAccessGranted); @Override ValidationResult validate(boolean simulate); @Override String getLabel();  }
@Test public void getLabel() { assertEquals("Modify Page", validator.getLabel()); }