Files
spring-restdocs/samples/testng/build.gradle
Andy Wilkinson 55cbdd505a Upgrade the samples to Spring Boot 2.4.x
Closes gh-723
2021-06-15 11:00:20 +01:00

60 lines
1.2 KiB
Groovy

plugins {
id "eclipse"
id "java"
id "org.asciidoctor.jvm.convert" version "3.3.2"
id "org.springframework.boot" version "2.4.7"
}
apply plugin: 'io.spring.dependency-management'
repositories {
mavenLocal()
maven { url 'https://repo.spring.io/milestone' }
maven { url 'https://repo.spring.io/snapshot' }
mavenCentral()
}
group = 'com.example'
sourceCompatibility = 1.8
targetCompatibility = 1.8
ext {
snippetsDir = file('build/generated-snippets')
}
ext['spring-restdocs.version'] = '2.0.6.BUILD-SNAPSHOT'
configurations {
asciidoctorExtensions
}
dependencies {
asciidoctorExtensions 'org.springframework.restdocs:spring-restdocs-asciidoctor'
implementation 'org.springframework.boot:spring-boot-starter-web'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
testImplementation 'org.springframework.restdocs:spring-restdocs-mockmvc'
testImplementation 'org.testng:testng:6.9.10'
}
test {
useTestNG()
outputs.dir snippetsDir
}
asciidoctor {
configurations "asciidoctorExtensions"
inputs.dir snippetsDir
dependsOn test
}
bootJar {
dependsOn asciidoctor
from ("${asciidoctor.outputDir}/html5") {
into 'static/docs'
}
}
eclipseJdt.onlyIf { false }
cleanEclipseJdt.onlyIf { false }