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