List of usage examples for org.springframework.context.support GenericApplicationContext publishEvent
@Override public void publishEvent(ApplicationEvent event)
From source file:net.sourceforge.vulcan.spring.AppCtxTest.java
public void testChildDoesNotReceiveFromParent() throws Exception { GenericApplicationContext parent = new GenericApplicationContext(); parent.refresh();/*from ww w .j a v a 2 s . c om*/ ac.setParent(parent); assertNotSame(evt, received); parent.publishEvent(evt); assertNotSame(evt, received); }
From source file:net.sourceforge.vulcan.spring.AppCtxTest.java
public void testParentReceivesFromChild() throws Exception { GenericApplicationContext child = new GenericApplicationContext(); child.setParent(this.ac); child.refresh();//from w ww .ja v a 2s. c o m assertNotSame(evt, received); child.publishEvent(evt); assertSame(evt, received); }