* Update to dependency-management-1.0.0.RC2 * Update to spring-io-plugin 0.0.6.RELEASE * Update to Boot 1.5 (which requires newer dependency management plugin)
58 lines
1.5 KiB
Groovy
58 lines
1.5 KiB
Groovy
buildscript {
|
|
repositories {
|
|
mavenCentral()
|
|
maven { url "https://repo.spring.io/plugins-snapshot" }
|
|
}
|
|
dependencies {
|
|
classpath("org.springframework.boot:spring-boot-gradle-plugin:$springBootVersion")
|
|
}
|
|
}
|
|
|
|
apply plugin: 'org.springframework.boot'
|
|
|
|
apply from: JAVA_GRADLE
|
|
apply from: SAMPLE_GRADLE
|
|
|
|
group = 'samples'
|
|
|
|
dependencies {
|
|
compile project(':spring-session-jdbc'),
|
|
"org.springframework.boot:spring-boot-starter-jdbc",
|
|
"org.springframework.boot:spring-boot-starter-web",
|
|
"org.springframework.boot:spring-boot-starter-security",
|
|
"org.springframework.boot:spring-boot-starter-thymeleaf",
|
|
"nz.net.ultraq.thymeleaf:thymeleaf-layout-dialect",
|
|
"org.thymeleaf.extras:thymeleaf-extras-conditionalcomments",
|
|
"org.webjars:bootstrap:$bootstrapVersion",
|
|
"org.webjars:html5shiv:$html5ShivVersion",
|
|
"org.webjars:webjars-locator",
|
|
"com.h2database:h2"
|
|
|
|
testCompile "org.springframework.boot:spring-boot-starter-test"
|
|
|
|
integrationTestCompile gebDependencies,
|
|
"org.spockframework:spock-spring:$spockVersion"
|
|
|
|
}
|
|
|
|
integrationTest {
|
|
doFirst {
|
|
def port = reservePort()
|
|
|
|
def host = 'localhost:' + port
|
|
systemProperties['geb.build.baseUrl'] = 'http://'+host+'/'
|
|
systemProperties['geb.build.reportsDir'] = 'build/geb-reports'
|
|
systemProperties['server.port'] = port
|
|
systemProperties['management.port'] = 0
|
|
|
|
systemProperties['spring.session.redis.namespace'] = project.name
|
|
}
|
|
}
|
|
|
|
def reservePort() {
|
|
def socket = new ServerSocket(0)
|
|
def result = socket.localPort
|
|
socket.close()
|
|
result
|
|
}
|