constraints.required(),
constraints.minLength(2)}),
constraints.not(
constraints.eqProperty("firstName", "lastName")));
rules.add(new CompoundPropertyConstraint(constraint));
BeanValidationResultsCollector c = new BeanValidationResultsCollector(p);
c.setCollectAllErrors(true);
BeanValidationResults r = c.collectResults(rules);
assertEquals(3, r.getViolatedCount());
String message =
r.getResults("firstName").buildMessage(Locale.getDefault());
System.out.println(message);
assertEquals(