@Test public void testRegisterPipelineForProviderType() { verifyPipelineIsNotRegistered(pipeline); pipelineRegistry.registerPipeline(pipeline, providerType); verifyPipelineIsRegisteredForProviderType(pipeline, providerType); }
@Test public void testRegisterPipeline() { verifyPipelineIsNotRegistered(pipeline); pipelineRegistry.registerPipeline(pipeline); verifyPipelineIsRegistered(pipeline); }
List<Pipeline> pipelines = mockPipelineList("providerType", ELEMENTS_COUNT); registerPipelinesForProviderType(pipelines, providerType); registerPipelinesForProviderType(mockPipelineList("providerType1", ELEMENTS_COUNT), providerType1); registerPipelinesForProviderType(mockPipelineList("providerType2", ELEMENTS_COUNT), providerType2);
@Test public void testGetPipelineByName() { verifyPipelineIsNotRegistered(pipeline); pipelineRegistry.registerPipeline(pipeline); Pipeline result = pipelineRegistry.getPipelineByName(PIPELINE_ID); assertEquals(pipeline, result); }
@Test public void testGetPipelines() { List<Pipeline> result = pipelineRegistry.getPipelines(0, 1000, PipelineRegistry.PIPELINE_NAME_SORT, true); assertTrue(result.isEmpty()); List<Pipeline> pipelines = mockPipelineList("", ELEMENTS_COUNT); pipelines.forEach(pipeline -> pipelineRegistry.registerPipeline(pipeline)); result = pipelineRegistry.getPipelines(0, 1000, PipelineRegistry.PIPELINE_NAME_SORT, true); for (Pipeline pipeline : pipelines) { assertTrue(result.contains(pipeline)); } }
List<Pipeline> pipelines = mockPipelineList("providerType", ELEMENTS_COUNT); registerPipelinesForProviderType(pipelines, providerType); registerPipelinesForProviderType(mockPipelineList("providerType1", ELEMENTS_COUNT), providerType1); registerPipelinesForProviderType(mockPipelineList("providerType2", ELEMENTS_COUNT), providerType2);
@Test public void testGetPipelineByName() { verifyPipelineIsNotRegistered(pipeline); pipelineRegistry.registerPipeline(pipeline); Pipeline result = pipelineRegistry.getPipelineByName(PIPELINE_ID); assertEquals(pipeline, result); }
@Test public void testGetPipelines() { List<Pipeline> result = pipelineRegistry.getPipelines(0, 1000, PipelineRegistry.PIPELINE_NAME_SORT, true); assertTrue(result.isEmpty()); List<Pipeline> pipelines = mockPipelineList("", ELEMENTS_COUNT); pipelines.forEach(pipeline -> pipelineRegistry.registerPipeline(pipeline)); result = pipelineRegistry.getPipelines(0, 1000, PipelineRegistry.PIPELINE_NAME_SORT, true); for (Pipeline pipeline : pipelines) { assertTrue(result.contains(pipeline)); } }
@Test public void testRegisterPipelineForProviderType() { verifyPipelineIsNotRegistered(pipeline); pipelineRegistry.registerPipeline(pipeline, providerType); verifyPipelineIsRegisteredForProviderType(pipeline, providerType); }
@Test public void testRegisterPipeline() { verifyPipelineIsNotRegistered(pipeline); pipelineRegistry.registerPipeline(pipeline); verifyPipelineIsRegistered(pipeline); }