79 lines
2.1 KiB
Groovy
79 lines
2.1 KiB
Groovy
buildscript {
|
|
repositories {
|
|
mavenCentral()
|
|
mavenLocal()
|
|
maven { url "http://repo.spring.io/libs-snapshot-local" }
|
|
maven { url "http://repo.spring.io/libs-release-local" }
|
|
maven { url "http://repo.spring.io/libs-staging-local/" }
|
|
maven { url 'http://repo.spring.io/plugins-snapshot' }
|
|
maven { url "http://repo.spring.io/plugins-release-local" }
|
|
maven { url "http://repo.spring.io/plugins-staging-local/" }
|
|
}
|
|
dependencies {
|
|
classpath "org.springframework.boot:spring-boot-gradle-plugin:1.4.0.BUILD-SNAPSHOT"
|
|
classpath "org.springframework.cloud:spring-cloud-contract-gradle-plugin:${findProperty('verifierVersion') ?: verifierVersion}"
|
|
}
|
|
}
|
|
|
|
group = 'com.example'
|
|
version = '0.0.1-SNAPSHOT'
|
|
|
|
repositories {
|
|
mavenCentral()
|
|
mavenLocal()
|
|
maven { url "http://repo.spring.io/snapshot" }
|
|
maven { url "http://repo.spring.io/milestone" }
|
|
maven { url "http://repo.spring.io/libs-release-local" }
|
|
maven { url "http://repo.spring.io/libs-staging-local/" }
|
|
}
|
|
|
|
apply plugin: 'groovy'
|
|
apply plugin: 'spring-boot'
|
|
apply plugin: 'spring-cloud-contract'
|
|
apply plugin: 'maven-publish'
|
|
|
|
dependencyManagement {
|
|
imports {
|
|
mavenBom "org.springframework.cloud:spring-cloud-dependencies:$BOM_VERSION"
|
|
mavenBom "org.springframework.cloud:spring-cloud-contract-dependencies:${project.findProperty('verifierVersion') ?: verifierVersion}"
|
|
}
|
|
}
|
|
|
|
contractVerifier {
|
|
baseClassForTests = 'com.example.fraud.MvcTest'
|
|
}
|
|
|
|
dependencies {
|
|
compile("org.springframework.boot:spring-boot-starter-web")
|
|
compile("org.springframework.boot:spring-boot-starter-actuator")
|
|
|
|
testRuntime "org.spockframework:spock-spring"
|
|
testCompile "org.spockframework:spock-core"
|
|
testCompile "org.springframework:spring-test"
|
|
testCompile "com.jayway.restassured:spring-mock-mvc:2.9.0"
|
|
testCompile "junit:junit"
|
|
}
|
|
|
|
test {
|
|
testLogging {
|
|
exceptionFormat = 'full'
|
|
}
|
|
}
|
|
|
|
task wrapper(type: Wrapper) {
|
|
gradleVersion = '2.14'
|
|
}
|
|
|
|
task resolveDependencies {
|
|
doLast {
|
|
project.rootProject.allprojects.each { subProject ->
|
|
subProject.buildscript.configurations.each { configuration ->
|
|
configuration.resolve()
|
|
}
|
|
subProject.configurations.each { configuration ->
|
|
configuration.resolve()
|
|
}
|
|
}
|
|
}
|
|
}
|