use of org.talend.components.api.service.common.testcomponent.inject.TestInjectComponentProperties in project components by Talend.
the class DefintitionRegistryTest method testCreateNewPropertiesWithInjected.
@Test
public void testCreateNewPropertiesWithInjected() {
DefinitionRegistryService registry = new DefinitionRegistry();
TestInjectComponentDefinition def = new TestInjectComponentDefinition();
TestInjectComponentProperties testProps = (TestInjectComponentProperties) registry.createProperties(def, "testProps");
assertThat(testProps.getDefinitionRegistry(), equalTo(registry));
}
use of org.talend.components.api.service.common.testcomponent.inject.TestInjectComponentProperties in project components by Talend.
the class DefintitionRegistryTest method testInjectDefinitionRegistry.
@Test
public void testInjectDefinitionRegistry() {
DefinitionRegistry registry = new DefinitionRegistry();
TestInjectComponentProperties properties = new TestInjectComponentProperties("props");
registry.injectDefinitionRegistry(properties);
assertThat((DefinitionRegistry) properties.getDefinitionRegistry(), equalTo(registry));
}
Aggregations