-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
52 lines (46 loc) · 2.06 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
buildscript {
ext {
compose_version = '1.3.0-alpha01'
}
dependencies {
classpath "com.google.dagger:hilt-android-gradle-plugin:2.42"
classpath "org.jacoco:org.jacoco.core:0.8.8"
classpath "org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:3.3"
}
}// Top-level build file where you can add configuration options common to all sub-projects/modules.
plugins {
id 'com.android.application' version '7.2.1' apply false
id 'com.android.library' version '7.2.1' apply false
id 'org.jetbrains.kotlin.android' version '1.7.0' apply false
}
allprojects {
apply plugin: 'jacoco'
apply plugin: 'org.sonarqube' // added for sonarQube
}
sonarqube {
properties {
property 'sonar.organization', "garyfimo"
property 'sonar.projectKey', "Garyfimo_MarvelApiTest"
property "sonar.language", "kotlin"
property "sonar.sourceEncoding", "UTF-8"
property 'sonar.host.url', "https://sonarcloud.io"
property 'sonar.coverage.jacoco.xmlReportPaths', "**/build/reports/jacoco/testDebugUnitTestCoverage/testDebugUnitTestCoverage.xml"
property 'sonar.coverage.exclusions', "**/model/**"
property "sonar.sources", "src/main/java"
property "sonar.binaries", "build/intermediates/classes/debug"
property "sonar.java.binaries", "build/intermediates/classes/debug"
property "sonar.tests", "src/test/java, src/androidTest/java"
property "sonar.java.test.binaries", "build/intermediates/classes/debug"
def unit = fileTree(dir: project.projectDir, includes: ['**/*.exec']).files;
def ui = fileTree(dir: project.projectDir, includes: ['**/*.ec']).files;
unit.addAll(ui);
def files = unit.join(", ");
property "sonar.jacoco.reportPaths", files
property "sonar.java.coveragePlugin", "jacoco"
property "sonar.junit.reportsPath", "build/test-results/testDebugUnitTest"
property "sonar.android.lint.report", "build/reports/lint-results.xml"
}
}
task clean(type: Delete) {
delete rootProject.buildDir
}