assertEquals(1, messages.getAllMessages().length);
assertEquals(1, messages.getMessagesBySource("errors-external").length);
}
public void testValidateWithErrorsForBeanValidatorOverridden() {
StaticApplicationContext applicationContext = new StaticApplicationContext();
applicationContext.registerSingleton("modelValidator", StubModelErrorsOverridden.class);
((Flow) requestContext.getActiveFlow()).setApplicationContext(applicationContext);
ValidationHelper helper = new ValidationHelper(new Object(), requestContext, eventId, modelName, null, null);
helper.validate();
MessageContext messages = requestContext.getMessageContext();
assertEquals(1, messages.getAllMessages().length);