import org.springframework.validation.MapBindingResult;
public class MessageContextErrorsTests extends TestCase {
public void testReject() {
StaticMessageSource messageSource = new StaticMessageSource();
messageSource.addMessage("foo", Locale.getDefault(), "bar");
messageSource.addMessage("bar", Locale.getDefault(), "{0}");
DefaultMessageContext context = new DefaultMessageContext(messageSource);
Object object = new Object();
MessageContextErrors errors = new MessageContextErrors(context, "object", object, null, null);