diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml index b632014..5d0f337 100644 --- a/.github/workflows/qa.yml +++ b/.github/workflows/qa.yml @@ -81,6 +81,26 @@ jobs: - name: Assert run: | ./test/assertFileExists ./output.properties + dontFailGradleKotlinTest: + name: > + Don't fail on Kotlin Gradle project + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + token: ${{ secrets.GITHUB_TOKEN }} + - name: Run action on Kotlin Gradle project + id: runTest + uses: ./ + continue-on-error: true + env: + SONAR_HOST_URL: http://not_actually_used + with: + projectBaseDir: ./test/gradle-project + args: -Dsonar.scanner.dumpToFile=./output.properties + - name: Assert + run: | + ./test/assertFileExists ./output.properties dontFailMavenTest: name: > Don't fail on Maven project diff --git a/entrypoint.sh b/entrypoint.sh index 24911d0..2bdd5d5 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -25,7 +25,7 @@ if [[ -f "${INPUT_PROJECTBASEDIR%/}/pom.xml" ]]; then to get more accurate results." fi -if [[ -f "${INPUT_PROJECTBASEDIR%/}/build.gradle" ]]; then +if [[ -f "${INPUT_PROJECTBASEDIR%/}/build.gradle" || -f "${INPUT_PROJECTBASEDIR%/}/build.gradle.kts" ]]; then echo "WARNING! Gradle project detected. Sonar recommends using the SonarQube plugin for Gradle during the build process instead of using this GitHub Action to get more accurate results." fi diff --git a/test/gradle-project-kotlin/build.gradle.kts b/test/gradle-project-kotlin/build.gradle.kts new file mode 100644 index 0000000..e69de29