public void testWorkingMemoryEventListener() {
final KnowledgeBase rb = KnowledgeBaseFactory.newKnowledgeBase();
final StatefulKnowledgeSession wm = rb.newStatefulKnowledgeSession();
final List wmList = new ArrayList();
final WorkingMemoryEventListener workingMemoryListener = new WorkingMemoryEventListener() {
public void objectInserted(ObjectInsertedEvent event) {
wmList.add( event );
}
public void objectUpdated(ObjectUpdatedEvent event) {