HashtagsXRep/hashtagsxrep

View on GitHub
build.gradle

Summary

Maintainability
Test Coverage
buildscript {
    repositories {
        mavenLocal()
        mavenCentral()
        gradlePluginPortal()
    }
    dependencies {
        classpath 'org.unbroken-dome.gradle-plugins:gradle-testsets-plugin:1.5.1'
    }
}
plugins {
    id 'idea'
    id 'application'
    id 'war'
    id 'checkstyle'
    id 'jacoco'
    id 'org.unbroken-dome.test-sets' version '2.1.1'
}
allprojects {
    repositories {
        mavenLocal()
        mavenCentral()
    }
}

group = 'cat.xarxarepublicana.hashtagsxrep'
version = '1.0'
description = 'hashtagsxrep'
sourceCompatibility = '1.8'

apply plugin: 'war'

dependencies {
    implementation 'org.springframework.boot:spring-boot-starter-web:2.1.4.RELEASE'
    implementation 'org.springframework.boot:spring-boot-starter-freemarker:2.1.4.RELEASE'
    implementation 'org.springframework.boot:spring-boot-starter-security:2.1.4.RELEASE'
    implementation 'io.jsonwebtoken:jjwt:0.9.1'
    implementation 'org.springframework.security:spring-security-taglibs:5.1.5.RELEASE'
    implementation 'org.apache.tomcat:tomcat-jsp-api:9.0.17'
    implementation 'com.github.scribejava:scribejava-core:6.1.0'
    implementation 'org.mybatis.spring.boot:mybatis-spring-boot-starter:1.3.2'
    implementation 'org.mariadb.jdbc:mariadb-java-client:2.4.1'
    implementation 'com.zaxxer:HikariCP:3.2.0'
    implementation 'io.projectreactor:reactor-core:3.2.6.RELEASE'
    implementation 'org.apache.commons:commons-lang3:3.8.1'
    implementation 'org.apache.commons:commons-text:1.6'
    implementation 'com.github.ben-manes.caffeine:caffeine:2.6.2'

    // Lombok
    compileOnly("org.projectlombok:lombok:1.18.10")
    annotationProcessor("org.projectlombok:lombok:1.18.10")

    providedRuntime 'org.springframework.boot:spring-boot-starter-tomcat:2.1.4.RELEASE'

    testImplementation 'org.springframework.boot:spring-boot-starter-test:2.1.4.RELEASE'
    testImplementation("org.junit.jupiter:junit-jupiter-api:5.5.0")
    testImplementation("org.junit.jupiter:junit-jupiter-params:5.5.2")
    testRuntime("org.junit.vintage:junit-vintage-engine:5.5.2")
    testRuntime("org.junit.jupiter:junit-jupiter-engine:5.5.2")
    testImplementation "org.testcontainers:junit-jupiter:1.12.3"
    testImplementation 'org.testcontainers:mariadb:1.12.3'
    testImplementation("org.mockito:mockito-inline:2.23.0")
    testImplementation("org.mockito:mockito-junit-jupiter:2.27.0")
    testImplementation("org.assertj:assertj-core:3.11.0")
    testImplementation 'net.sourceforge.htmlunit:htmlunit:2.36.0'
    testImplementation 'commons-io:commons-io:2.6'
}

mainClassName = 'cat.xarxarepublicana.hashtagsxrep.HashtagsXRepApplication'

war {
    archiveName = 'ROOT.war'
}

tasks.withType(JavaCompile) {
    options.encoding = 'UTF-8'
    options.compilerArgs << '-parameters'
}

testSets {
    integrationTest { dirName = 'integrationTest' }
}
test {
    useJUnitPlatform()
}
integrationTest {
    useJUnitPlatform()
}

checkstyle {
    toolVersion '7.8.1'
    sourceSets = [project.sourceSets.main, project.sourceSets.test, project.sourceSets.integrationTest]
    ignoreFailures = false
    configFile file("checkstyle/checkstyle_config.xml")
}

jacocoTestReport {
    executionData = fileTree(buildDir).include("/jacoco/*.exec")
    reports {
        xml.enabled true
        html.enabled true
    }
}

check.dependsOn integrationTest
integrationTest.mustRunAfter test
check.dependsOn jacocoTestReport