use of com.thoughtworks.go.server.service.tasks.PluggableTaskService in project gocd by gocd.
the class TemplateConfigServiceTest method setup.
@Before
public void setup() {
goConfigService = mock(GoConfigService.class);
securityService = mock(SecurityService.class);
entityHashingService = mock(EntityHashingService.class);
pluggableTaskService = mock(PluggableTaskService.class);
service = new TemplateConfigService(goConfigService, securityService, entityHashingService, pluggableTaskService);
}
use of com.thoughtworks.go.server.service.tasks.PluggableTaskService in project gocd by gocd.
the class PipelineConfigServiceTest method setUp.
@Before
public void setUp() throws Exception {
PipelineConfigs configs = createGroup("group", "pipeline", "in_env");
downstream(configs);
cruiseConfig = new BasicCruiseConfig(configs);
cruiseConfig.addEnvironment(environment("foo", "in_env"));
PipelineConfig remotePipeline = PipelineConfigMother.pipelineConfig("remote");
remotePipeline.setOrigin(new RepoConfigOrigin(new ConfigRepoConfig(new GitMaterialConfig("url"), "plugin"), "1234"));
cruiseConfig.addPipeline("group", remotePipeline);
goConfigService = mock(GoConfigService.class);
securityService = mock(SecurityService.class);
pluggableTaskService = mock(PluggableTaskService.class);
when(goConfigService.getCurrentConfig()).thenReturn(cruiseConfig);
when(goConfigService.cruiseConfig()).thenReturn(cruiseConfig);
when(goConfigService.getConfigForEditing()).thenReturn(cruiseConfig);
when(goConfigService.getMergedConfigForEditing()).thenReturn(cruiseConfig);
when(goConfigService.getAllPipelineConfigs()).thenReturn(cruiseConfig.getAllPipelineConfigs());
pipelineConfigService = new PipelineConfigService(goConfigService, securityService, pluggableTaskService, null);
}
Aggregations