DDConfigUpdater { public void processResourceAdd(@Observes final ResourceAddedEvent resourceAddedEvent) { if (configUpdaterHelper.isPersistenceFile(resourceAddedEvent.getPath())) { updateConfig(moduleService.resolveModule(resourceAddedEvent.getPath())); } } DDConfigUpdater(); @Inject  DDConfigUpdater(DDEditorService ddEditorService,
                           KieModuleService moduleService,
                           DDConfigUpdaterHelper configUpdaterHelper); void processResourceAdd(@Observes final ResourceAddedEvent resourceAddedEvent); void processResourceUpdate(@Observes final ResourceUpdatedEvent resourceUpdatedEvent); void processWorkitemInstall(@Observes final DesignerWorkitemInstalledEvent workitemInstalledEvent); void processServiceTaskEvent(@Observes final ServiceTaskResourceEvent serviceResourceEvent); String parseWorkitemValue(String value); String getWorkitemResolver(String value,
                                      String defaultResolver); boolean isValidWorkitem(String name, String value);  }
@Test public void testProcessResourceAdd() { ddConfigUpdater.processResourceAdd(new ResourceAddedEvent(Mockito.mock(Path.class), "test resource", Mockito.mock(SessionInfo.class))); assertNotNull(model.getMarshallingStrategies()); assertEquals(1, model.getMarshallingStrategies().size()); ItemObjectModel objectModel = model.getMarshallingStrategies().get(0); assertNotNull(objectModel); assertEquals(JPA_MARSHALLING_STRATEGY, objectModel.getValue()); assertEquals("mvel", objectModel.getResolver()); }