train_getCount(context, 0);
replay();
ComponentEvent event = new ComponentEventImpl("eventType", "someId", context, handler, null);
event.setMethodDescription("foo.Bar.baz()");
try
{
event.coerceContext(1, "java.lang.Integer");
}
catch (IllegalArgumentException ex)
{
assertEquals(ex.getMessage(),
"Method foo.Bar.baz() has more parameters than there are context values for this component event.");