@Test
public void trigger_immediate()
{
FormSupport support = mockFormSupport();
ComponentResources resources = mockComponentResources();
Heartbeat heartbeat = new HeartbeatImpl();
Request request = mockRequest();
String elementName = "myname";
train_getParameter(request, elementName, "login");
replay();
heartbeat.begin();
Submit submit = new Submit(request);
submit.setup(resources, support, heartbeat);
submit.setDefer(false);
submit.processSubmission(support, elementName);
verify();
expect(resources.triggerEvent(Submit.SELECTED_EVENT, null, null)).andReturn(false);
replay();
heartbeat.end();