Search in sources :

Example 1 with DefaultDefinitionsCacheRegistry

use of org.kie.workbench.common.stunner.core.registry.impl.DefaultDefinitionsCacheRegistry in project kie-wb-common by kiegroup.

the class StunnerTestingMockAPI method initInstances.

protected void initInstances() {
    definitionManager = mock(DefinitionManager.class);
    definitionSetRegistry = mock(TypeDefinitionSetRegistry.class);
    adapterManager = mock(AdapterManager.class);
    adapterRegistry = mock(AdapterRegistry.class);
    ruleManager = mock(RuleManager.class);
    initFactory();
    definitionUtils = spy(new DefinitionUtils(definitionManager, new DefaultDefinitionsCacheRegistry(factoryManager, adapterManager)));
    initAdapters();
}
Also used : DefinitionManager(org.kie.workbench.common.stunner.core.api.DefinitionManager) TypeDefinitionSetRegistry(org.kie.workbench.common.stunner.core.registry.definition.TypeDefinitionSetRegistry) AdapterManager(org.kie.workbench.common.stunner.core.definition.adapter.AdapterManager) DefinitionUtils(org.kie.workbench.common.stunner.core.util.DefinitionUtils) RuleManager(org.kie.workbench.common.stunner.core.rule.RuleManager) AdapterRegistry(org.kie.workbench.common.stunner.core.registry.definition.AdapterRegistry) DefaultDefinitionsCacheRegistry(org.kie.workbench.common.stunner.core.registry.impl.DefaultDefinitionsCacheRegistry)

Example 2 with DefaultDefinitionsCacheRegistry

use of org.kie.workbench.common.stunner.core.registry.impl.DefaultDefinitionsCacheRegistry in project kie-wb-common by kiegroup.

the class DefinitionUtilsTest method setUp.

@Before
public void setUp() throws Exception {
    graphMockHandler = new TestingGraphMockHandler();
    domainObject = new TestingSimpleDomainObject(graphMockHandler);
    tested = new DefinitionUtils(graphMockHandler.getDefinitionManager(), new DefaultDefinitionsCacheRegistry(graphMockHandler.getFactoryManager(), graphMockHandler.getAdapterManager()));
}
Also used : TestingGraphMockHandler(org.kie.workbench.common.stunner.core.TestingGraphMockHandler) TestingSimpleDomainObject(org.kie.workbench.common.stunner.core.TestingSimpleDomainObject) DefaultDefinitionsCacheRegistry(org.kie.workbench.common.stunner.core.registry.impl.DefaultDefinitionsCacheRegistry) Before(org.junit.Before)

Aggregations

DefaultDefinitionsCacheRegistry (org.kie.workbench.common.stunner.core.registry.impl.DefaultDefinitionsCacheRegistry)2 Before (org.junit.Before)1 TestingGraphMockHandler (org.kie.workbench.common.stunner.core.TestingGraphMockHandler)1 TestingSimpleDomainObject (org.kie.workbench.common.stunner.core.TestingSimpleDomainObject)1 DefinitionManager (org.kie.workbench.common.stunner.core.api.DefinitionManager)1 AdapterManager (org.kie.workbench.common.stunner.core.definition.adapter.AdapterManager)1 AdapterRegistry (org.kie.workbench.common.stunner.core.registry.definition.AdapterRegistry)1 TypeDefinitionSetRegistry (org.kie.workbench.common.stunner.core.registry.definition.TypeDefinitionSetRegistry)1 RuleManager (org.kie.workbench.common.stunner.core.rule.RuleManager)1 DefinitionUtils (org.kie.workbench.common.stunner.core.util.DefinitionUtils)1