You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
spring-camel-template/build.gradle

114 lines
3.3 KiB

gradle.startParameter.showStacktrace = ShowStacktrace.ALWAYS
buildscript {
ext {
ext.mavenRepo = 'http://localhost:18081/repository/maven-central/'
springBootVersion = '2.6.7'
springCloudVersion = '2021.0.1'
liquibaseCoreVersion = '3.8.9'
liquibasePluginVersion = '2.1.1'
logbackVersion = '1.2.9'
jacksonVersion = '2.11.0'
validationApiVersion = '2.0.1.Final'
hibernateValidator = '6.2.0.Final'
jakartaValidation = '2.0.2'
}
repositories {
maven {
allowInsecureProtocol true
url mavenRepo
}
}
dependencies {
classpath "org.springframework.boot:spring-boot-gradle-plugin:${springBootVersion}"
classpath "org.liquibase:liquibase-gradle-plugin:${liquibasePluginVersion}"
}
}
subprojects {
apply plugin: 'java'
apply plugin: 'org.springframework.boot'
apply plugin: 'io.spring.dependency-management'
group = 'me.bvn13.service'
version = '0.0.1'
sourceCompatibility = 17
targetCompatibility = 17
tasks.withType(JavaCompile) {
options.encoding = 'UTF-8'
}
configurations {
compileOnly {
extendsFrom annotationProcessor
}
}
repositories {
maven {
allowInsecureProtocol true
url mavenRepo
}
}
//------------------- Настройка интеграционных тестов (start) ---------------------
sourceSets {
integrationTest {
java {
compileClasspath += sourceSets.main.output
runtimeClasspath += sourceSets.main.output
compileClasspath += sourceSets.test.output
runtimeClasspath += sourceSets.test.output
srcDir file('src/integration-test/java')
}
resources.srcDir file('src/integration-test/resources')
}
}
configurations {
integrationTestImplementation.extendsFrom testImplementation
integrationTestRuntimeOnly.extendsFrom testRuntimeOnly
}
task integrationTest(type: Test) {
testClassesDirs = sourceSets.integrationTest.output.classesDirs
classpath = sourceSets.integrationTest.runtimeClasspath
outputs.upToDateWhen { false }
}
check.dependsOn integrationTest
integrationTest.mustRunAfter test
//------------------- Настройка интеграционных тестов (end) ---------------------
dependencies {
implementation 'org.springframework.boot:spring-boot-starter'
compileOnly 'org.projectlombok:lombok'
annotationProcessor 'org.projectlombok:lombok'
testImplementation('org.springframework.boot:spring-boot-starter-test') {
exclude group: 'org.junit.vintage', module: 'junit-vintage-engine'
}
testCompileOnly "org.projectlombok:lombok"
testAnnotationProcessor("org.projectlombok:lombok")
testImplementation 'org.assertj:assertj-core'
testImplementation 'org.mockito:mockito-core'
}
test {
useJUnitPlatform()
systemProperties System.properties
// Нужно, иначе Jacoco не работает
systemProperties['user.dir'] = workingDir
}
integrationTest {
useJUnitPlatform()
systemProperties System.properties
}
}