diff --git a/build.gradle b/build.gradle index ad814196..71c6d374 100644 --- a/build.gradle +++ b/build.gradle @@ -1,7 +1,6 @@ import java.util.jar.JarInputStream plugins { - id 'java' id 'com.jfrog.artifactory' version '4.28.2' id 'org.sonarqube' version '3.5.0.2730' id 'de.thetaphi.forbiddenapis' version '3.0' apply false @@ -14,16 +13,6 @@ allprojects { apply plugin: 'maven-publish' apply plugin: 'signing' - gradle.projectsEvaluated { - tasks.withType(JavaCompile).configureEach { - if (project.hasProperty('warn')) { - options.compilerArgs << "-Xlint:unchecked" << "-Xlint:deprecation" - } else { - options.compilerArgs << "-Xlint:-unchecked" << "-Xlint:-deprecation" - } - } - } - ext { buildNumber = System.getProperty("buildNumber") @@ -69,13 +58,7 @@ subprojects { testCompile.extendsFrom compileOnly } - if (!project.path.startsWith(":its")) { - test { - useJUnitPlatform() - } - } - - test { + tasks.withType(Test).configureEach { def propKeys = System.properties.findAll { it.key.startsWith("orchestrator") || it.key.startsWith("sonar") || it.key == "buildNumber" || it.key == "slangVersion" }.collect { it.key } diff --git a/its/plugin/src/test/java/org/sonarsource/slang/MeasuresTest.java b/its/plugin/src/test/java/org/sonarsource/slang/MeasuresTest.java index 48411f4f..25d22214 100644 --- a/its/plugin/src/test/java/org/sonarsource/slang/MeasuresTest.java +++ b/its/plugin/src/test/java/org/sonarsource/slang/MeasuresTest.java @@ -35,10 +35,6 @@ public void go_measures() { assertThat(getMeasureAsInt(componentKey, "ncloc")).isEqualTo(41); assertThat(getMeasureAsInt(componentKey, "comment_lines")).isEqualTo(2); - assertThat(getMeasure(componentKey, "ncloc_data").getValue()) - .isEqualTo("1=1;3=1;4=1;5=1;6=1;7=1;8=1;10=1;11=1;12=1;13=1;14=1;16=1;17=1;18=1;20=1;21=1;22=1;23=1;24=1;25=1;" + - "26=1;27=1;28=1;29=1;30=1;31=1;32=1;33=1;35=1;36=1;37=1;38=1;39=1;40=1;41=1;46=1;47=1;48=1;49=1;50=1"); - assertThat(getMeasureAsInt(componentKey, "functions")).isEqualTo(3); assertThat(getMeasure(componentKey, "executable_lines_data").getValue()) diff --git a/settings.gradle b/settings.gradle index 0ba7343b..4965002a 100644 --- a/settings.gradle +++ b/settings.gradle @@ -48,7 +48,7 @@ dependencyResolutionManagement { rootProject.name = 'sonar-go' -include 'sonar-go-to-slang' -include 'sonar-go-plugin' -include 'its:plugin' -include 'its:ruling' +include ':sonar-go-to-slang' +include ':sonar-go-plugin' +include ':its:plugin' +include ':its:ruling'