spring-boot/integration-test/spring-boot-sni-integration.../build.gradle

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

103 lines
4.1 KiB
Groovy
Raw Permalink Normal View History

/*
* Copyright 2012-present the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the License);
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
plugins {
id "java"
id "org.springframework.boot.integration-test"
}
description = "Spring Boot SNI Integration Tests"
configurations {
app
}
dependencies {
app project(path: ":platform:spring-boot-dependencies", configuration: "mavenRepository")
app project(path: ":module:spring-boot-restclient", configuration: "mavenRepository")
app project(path: ":starter:spring-boot-starter", configuration: "mavenRepository")
app project(path: ":starter:spring-boot-starter-actuator", configuration: "mavenRepository")
app project(path: ":starter:spring-boot-starter-tomcat", configuration: "mavenRepository")
app project(path: ":starter:spring-boot-starter-webmvc", configuration: "mavenRepository")
app project(path: ":starter:spring-boot-starter-webflux", configuration: "mavenRepository")
app project(path: ":build-plugin:spring-boot-gradle-plugin", configuration: "mavenRepository")
app project(path: ":module:spring-boot-webflux", configuration: "mavenRepository")
intTestImplementation(enforcedPlatform(project(":platform:spring-boot-internal-dependencies")))
intTestImplementation(project(":starter:spring-boot-starter-webmvc"))
intTestImplementation(project(":test-support:spring-boot-test-support"))
intTestImplementation(project(":starter:spring-boot-starter-test"))
intTestImplementation("org.testcontainers:testcontainers-junit-jupiter")
}
tasks.register("syncMavenRepository", Sync) {
from configurations.app
into layout.buildDirectory.dir("int-test-maven-repository")
}
tasks.register("syncReactiveServerAppSource", org.springframework.boot.build.SyncAppSource) {
sourceDirectory = file("spring-boot-sni-reactive-app")
destinationDirectory = file(layout.buildDirectory.dir("spring-boot-sni-reactive-app"))
}
tasks.register("buildReactiveServerApps", GradleBuild) {
dependsOn syncReactiveServerAppSource, syncMavenRepository
dir = layout.buildDirectory.dir("spring-boot-sni-reactive-app")
startParameter.buildCacheEnabled = false
tasks = [
"nettyServerApp",
"tomcatServerApp"
]
}
tasks.register("syncServletServerAppSource", org.springframework.boot.build.SyncAppSource) {
sourceDirectory = file("spring-boot-sni-servlet-app")
destinationDirectory = file(layout.buildDirectory.dir("spring-boot-sni-servlet-app"))
}
tasks.register("buildServletServerApps", GradleBuild) {
dependsOn syncServletServerAppSource, syncMavenRepository
dir = layout.buildDirectory.dir("spring-boot-sni-servlet-app")
startParameter.buildCacheEnabled = false
tasks = [
"tomcatServerApp"
]
}
tasks.register("syncClientAppSource", org.springframework.boot.build.SyncAppSource) {
sourceDirectory = file("spring-boot-sni-client-app")
destinationDirectory = file(layout.buildDirectory.dir("spring-boot-sni-client-app"))
}
tasks.register("buildClientApp", GradleBuild) {
dependsOn syncClientAppSource, syncMavenRepository
dir = layout.buildDirectory.dir("spring-boot-sni-client-app")
startParameter.buildCacheEnabled = false
tasks = ["build"]
}
intTest {
inputs.files(
layout.buildDirectory.file("spring-boot-server-tests-app/build/libs/spring-boot-server-tests-app-netty-reactive.jar"),
layout.buildDirectory.file("spring-boot-server-tests-app/build/libs/spring-boot-server-tests-app-tomcat-reactive.jar"),
layout.buildDirectory.file("spring-boot-server-tests-app/build/libs/spring-boot-server-tests-app-tomcat-servlet.jar")
)
.withPropertyName("applicationArchives")
.withPathSensitivity(PathSensitivity.RELATIVE)
.withNormalizer(ClasspathNormalizer)
dependsOn buildReactiveServerApps, buildServletServerApps, buildClientApp
}