]> source.dussan.org Git - sonarqube.git/commitdiff
fix quality flaw
authorTeryk Bellahsene <teryk.bellahsene@sonarsource.com>
Tue, 9 Dec 2014 15:06:42 +0000 (16:06 +0100)
committerTeryk Bellahsene <teryk.bellahsene@sonarsource.com>
Tue, 9 Dec 2014 15:06:42 +0000 (16:06 +0100)
server/sonar-server/src/main/java/org/sonar/server/batch/UploadReportAction.java
server/sonar-server/src/test/java/org/sonar/server/batch/BatchWsTest.java
server/sonar-server/src/test/java/org/sonar/server/batch/UploadReportActionTest.java

index 276b0ce66cc102f4add3fc8d967b2d97141b8ad9..a50ba5f9729dc923905f44033544c4efade93c39 100644 (file)
@@ -26,7 +26,6 @@ import org.sonar.api.server.ws.Response;
 import org.sonar.api.server.ws.WebService;
 import org.sonar.server.computation.AnalysisReportQueue;
 import org.sonar.server.computation.AnalysisReportTaskLauncher;
-import org.sonar.server.computation.ComputationService;
 
 public class UploadReportAction implements RequestHandler {
 
@@ -36,12 +35,10 @@ public class UploadReportAction implements RequestHandler {
   static final String PARAM_SNAPSHOT = "snapshot";
 
   private final AnalysisReportQueue analysisReportQueue;
-  private final ComputationService computationService;
   private final AnalysisReportTaskLauncher analysisTaskLauncher;
 
-  public UploadReportAction(AnalysisReportQueue analysisReportQueue, ComputationService computationService, AnalysisReportTaskLauncher analysisTaskLauncher) {
+  public UploadReportAction(AnalysisReportQueue analysisReportQueue, AnalysisReportTaskLauncher analysisTaskLauncher) {
     this.analysisReportQueue = analysisReportQueue;
-    this.computationService = computationService;
     this.analysisTaskLauncher = analysisTaskLauncher;
   }
 
index 456393159ec827870123984519ffaa6b0afeda7a..bf762d18a7aa9871b4c45ac283233fd734ad6d82 100644 (file)
@@ -32,7 +32,6 @@ import org.sonar.api.resources.Languages;
 import org.sonar.core.properties.PropertiesDao;
 import org.sonar.server.computation.AnalysisReportQueue;
 import org.sonar.server.computation.AnalysisReportTaskLauncher;
-import org.sonar.server.computation.ComputationService;
 import org.sonar.server.db.DbClient;
 import org.sonar.server.qualityprofile.QProfileFactory;
 import org.sonar.server.qualityprofile.QProfileLoader;
@@ -66,7 +65,7 @@ public class BatchWsTest {
       new GlobalReferentialsAction(mock(DbClient.class), mock(PropertiesDao.class)),
       new ProjectReferentialsAction(mock(DbClient.class), mock(PropertiesDao.class), mock(QProfileFactory.class), mock(QProfileLoader.class), mock(RuleService.class),
         mock(Languages.class)),
-      new UploadReportAction(mock(AnalysisReportQueue.class), mock(ComputationService.class), mock(AnalysisReportTaskLauncher.class))));
+      new UploadReportAction(mock(AnalysisReportQueue.class), mock(AnalysisReportTaskLauncher.class))));
   }
 
   @Test
index cd56bdf181e90c4d5c800c39ca3c462139f57d23..2c792c94f34ce4eaa8f39f38b0665e46adb718e8 100644 (file)
@@ -45,7 +45,7 @@ public class UploadReportActionTest {
     analysisTaskLauncher = mock(AnalysisReportTaskLauncher.class);
     queue = mock(AnalysisReportQueue.class);
 
-    sut = new UploadReportAction(queue, computationService, analysisTaskLauncher);
+    sut = new UploadReportAction(queue, analysisTaskLauncher);
   }
 
   @Test