use of org.apache.samza.context.ApplicationContainerContextFactory in project samza by apache.
the class TestStreamApplicationDescriptorImpl method testApplicationContainerContextFactory.
@Test
public void testApplicationContainerContextFactory() {
ApplicationContainerContextFactory factory = mock(ApplicationContainerContextFactory.class);
StreamApplication testApp = appDesc -> appDesc.withApplicationContainerContextFactory(factory);
StreamApplicationDescriptorImpl appSpec = new StreamApplicationDescriptorImpl(testApp, getConfig());
assertEquals(appSpec.getApplicationContainerContextFactory(), Optional.of(factory));
}
use of org.apache.samza.context.ApplicationContainerContextFactory in project samza by apache.
the class TestTaskApplicationDescriptorImpl method testApplicationContainerContextFactory.
@Test
public void testApplicationContainerContextFactory() {
ApplicationContainerContextFactory factory = mock(ApplicationContainerContextFactory.class);
TaskApplication testApp = appDesc -> appDesc.withApplicationContainerContextFactory(factory);
TaskApplicationDescriptorImpl appSpec = new TaskApplicationDescriptorImpl(testApp, mock(Config.class));
assertEquals(appSpec.getApplicationContainerContextFactory(), Optional.of(factory));
}
Aggregations