]> source.dussan.org Git - sonarqube.git/commitdiff
Fix timings in performance tests due to hardware/OS change
authorSimon Brandhof <simon.brandhof@sonarsource.com>
Tue, 1 Mar 2016 08:36:58 +0000 (09:36 +0100)
committerSimon Brandhof <simon.brandhof@sonarsource.com>
Tue, 1 Mar 2016 08:36:58 +0000 (09:36 +0100)
tests/perf/src/test/java/org/sonarsource/sonarqube/perf/scanner/suite/IssuesModeTest.java
tests/perf/src/test/java/org/sonarsource/sonarqube/perf/server/ServerTest.java

index 40577235054402e1c1d61149bbff39c7a84bba39..cced5e65d133adc7a831aecdeeaa61e2990e9035 100644 (file)
@@ -21,6 +21,7 @@ package org.sonarsource.sonarqube.perf.scanner.suite;
 
 import com.sonar.orchestrator.Orchestrator;
 import com.sonar.orchestrator.build.SonarRunner;
+import com.sonar.orchestrator.build.SonarScanner;
 import org.sonarsource.sonarqube.perf.PerfRule;
 import org.sonarsource.sonarqube.perf.PerfTestCase;
 import java.io.File;
@@ -57,7 +58,7 @@ public class IssuesModeTest extends PerfTestCase {
     File userHome = temp.newFolder();
     orchestrator.getServer().provisionProject("sample", "xoo-sample");
     orchestrator.getServer().associateProjectToQualityProfile("sample", "xoo", "one-xoo-issue-per-line");
-    SonarRunner runner = newScanner(
+    SonarScanner runner = newScanner(
       "-Xmx512m -server -XX:MaxPermSize=64m",
       "sonar.analysis.mode", "issues",
       "sonar.userHome", userHome.getAbsolutePath(),
@@ -67,7 +68,7 @@ public class IssuesModeTest extends PerfTestCase {
     long duration = System.currentTimeMillis() - start;
     System.out.println("Issues analysis: " + duration + "ms");
 
-    perfRule.assertDurationAround(duration, 4450L);
+    perfRule.assertDurationAround(duration, 5230L);
   }
 
   @Test
index ac4afed4fe9e4b01cb864921d2d9a9e100e20a42..36687d52c2d7a33500e2fb2d848c8e1d11258168 100644 (file)
@@ -47,7 +47,7 @@ public class ServerTest extends PerfTestCase {
       .build();
     try {
       long startupDuration = start(orchestrator);
-      assertDurationAround(startupDuration, 46000);
+      assertDurationAround(startupDuration, 41000);
 
       long shutdownDuration = stop(orchestrator);
       // can't use percent margins because logs are second-grained but not milliseconds