Search in sources :

Example 21 with Localizer

use of com.thoughtworks.go.i18n.Localizer in project gocd by gocd.

the class ScheduleServiceTest method createMocks.

private void createMocks() {
    jobInstanceService = mock(JobInstanceService.class);
    goConfigService = mock(GoConfigService.class);
    environmentConfigService = mock(EnvironmentConfigService.class);
    serverHealthService = mock(ServerHealthService.class);
    final TestTransactionSynchronizationManager synchronizationManager = new TestTransactionSynchronizationManager();
    schedulingChecker = mock(SchedulingCheckerService.class);
    pipelineScheduleQueue = mock(PipelineScheduleQueue.class);
    consoleActivityMonitor = mock(ConsoleActivityMonitor.class);
    pipelinePauseService = mock(PipelinePauseService.class);
    stageService = mock(StageService.class);
    securityService = mock(SecurityService.class);
    pipelineService = mock(PipelineService.class);
    localizer = mock(Localizer.class);
    timeProvider = new TimeProvider();
    schedulingPerformanceLogger = mock(SchedulingPerformanceLogger.class);
    elasticProfileService = mock(ElasticProfileService.class);
    stageOrderService = mock(StageOrderService.class);
    pipelineLockService = mock(PipelineLockService.class);
    service = new ScheduleService(goConfigService, pipelineService, stageService, schedulingChecker, mock(PipelineDao.class), mock(StageDao.class), stageOrderService, securityService, pipelineScheduleQueue, jobInstanceService, mock(JobInstanceDao.class), mock(AgentAssignment.class), environmentConfigService, pipelineLockService, serverHealthService, new TestTransactionTemplate(synchronizationManager), mock(AgentService.class), synchronizationManager, timeProvider, consoleActivityMonitor, pipelinePauseService, instanceFactory, schedulingPerformanceLogger, elasticProfileService);
}
Also used : TestTransactionTemplate(com.thoughtworks.go.server.transaction.TestTransactionTemplate) TimeProvider(com.thoughtworks.go.util.TimeProvider) TestTransactionSynchronizationManager(com.thoughtworks.go.server.transaction.TestTransactionSynchronizationManager) Localizer(com.thoughtworks.go.i18n.Localizer) SchedulingPerformanceLogger(com.thoughtworks.go.server.perf.SchedulingPerformanceLogger) ServerHealthService(com.thoughtworks.go.serverhealth.ServerHealthService)

Aggregations

Localizer (com.thoughtworks.go.i18n.Localizer)21 Test (org.junit.Test)14 Username (com.thoughtworks.go.server.domain.Username)5 HttpLocalizedOperationResult (com.thoughtworks.go.server.service.result.HttpLocalizedOperationResult)5 Before (org.junit.Before)5 GoConfigValidity (com.thoughtworks.go.config.validation.GoConfigValidity)3 PipelineGroupNotFoundException (com.thoughtworks.go.config.exceptions.PipelineGroupNotFoundException)2 Localizable (com.thoughtworks.go.i18n.Localizable)2 SchedulingPerformanceLogger (com.thoughtworks.go.server.perf.SchedulingPerformanceLogger)2 TestTransactionSynchronizationManager (com.thoughtworks.go.server.transaction.TestTransactionSynchronizationManager)2 TestTransactionTemplate (com.thoughtworks.go.server.transaction.TestTransactionTemplate)2 ServerHealthService (com.thoughtworks.go.serverhealth.ServerHealthService)2 TimeProvider (com.thoughtworks.go.util.TimeProvider)2 MockHttpServletRequest (org.springframework.mock.web.MockHttpServletRequest)2 MockHttpServletResponse (org.springframework.mock.web.MockHttpServletResponse)2 TaskExtension (com.thoughtworks.go.plugin.access.pluggabletask.TaskExtension)1 TaskPreference (com.thoughtworks.go.plugin.access.pluggabletask.TaskPreference)1 TaskConfig (com.thoughtworks.go.plugin.api.task.TaskConfig)1 TaskConfigProperty (com.thoughtworks.go.plugin.api.task.TaskConfigProperty)1 SecurityAuthConfigService (com.thoughtworks.go.server.service.SecurityAuthConfigService)1