]> source.dussan.org Git - sonarqube.git/commitdiff
SONAR-9586 Run incremental task when sonar.incremental=true
authorJulien HENRY <julien.henry@sonarsource.com>
Thu, 20 Jul 2017 14:33:37 +0000 (16:33 +0200)
committerJulien HENRY <julien.henry@sonarsource.com>
Mon, 7 Aug 2017 09:44:06 +0000 (11:44 +0200)
sonar-scanner-engine/src/test/java/org/sonar/scanner/mediumtest/tasks/TasksMediumTest.java

index 8d679016b61b648903f79ac04ba6cf2c1028267e..73e96a1a302d361da53c4ba279796e599a0df14e 100644 (file)
@@ -97,6 +97,20 @@ public class TasksMediumTest {
       .execute();
   }
 
+  @Test
+  public void incrementalNotFound() throws Exception {
+    tester.start();
+
+    thrown.expect(MessageException.class);
+    thrown.expectMessage(
+      "Incremental mode is not available. Please contact your administrator.");
+
+    tester.newTask()
+      .properties(ImmutableMap.<String, String>builder()
+        .put("sonar.incremental", "true").build())
+      .start();
+  }
+
   private static class FakeTaskPlugin extends SonarPlugin {
 
     @Override