]> source.dussan.org Git - sonarqube.git/commitdiff
IT using sonar.profile without provisioning project
authorDuarte Meneses <duarte.meneses@sonarsource.com>
Thu, 1 Oct 2015 16:10:31 +0000 (18:10 +0200)
committerDuarte Meneses <duarte.meneses@sonarsource.com>
Thu, 1 Oct 2015 16:10:31 +0000 (18:10 +0200)
it/it-tests/src/test/java/batch/BatchTest.java

index a3a7edadf6cb0db70ba026f5cc329cf3aeaca61b..b7bc903fd5ceddfca9d020b3a0508d4a8cf0bc89 100644 (file)
@@ -74,6 +74,15 @@ public class BatchTest {
     Resource branch = sonar.find(new ResourceQuery("com.sonarsource.it.samples:multi-modules-sample:branch/0.x"));
     assertThat(branch.getName()).isEqualTo("Sonar :: Integration Tests :: Multi-modules Sample branch/0.x");
   }
+  
+  @Test
+  public void use_sonar_profile_without_provisioning_project() {
+    scan("shared/xoo-multi-modules-sample",
+      "sonar.profile", "one-issue-per-line",
+      "sonar.verbose", "true");
+    Resource r = orchestrator.getServer().getWsClient().find(ResourceQuery.createForMetrics("com.sonarsource.it.samples:multi-modules-sample", "violations"));
+    assertThat(r.getMeasureIntValue("violations")).isEqualTo(61);
+  }
 
   /**
    * SONAR-2907