IFormComponent field = newField("My Field");
MockControl contextc = newControl(FormComponentContributorContext.class);
FormComponentContributorContext context = (FormComponentContributorContext) contextc
.getMock();
context.includeClasspathScript("/org/apache/tapestry/form/validator/NumberValidator.js");
trainFormatMessage(contextc, context, null, ValidationStrings.VALUE_TOO_SMALL, new Object[]
{ "My Field", new Double(20) }, "default message");
context.getFieldDOM();