|
1 | 1 | plugins { |
2 | | - id "se.bjurr.gradle.java-convention" version "0.+" |
3 | | - id "org.wiremock.tools.gradle.publishing" version "0.5.1" |
4 | | - id "org.wiremock.tools.gradle.java" version "0.5.1" |
5 | | - id "project-report" |
| 2 | + id "se.bjurr.gradle.bundle-jar" version "1.4.4" |
6 | 3 | } |
7 | 4 |
|
8 | | -sourceCompatibility = 17 |
9 | | -targetCompatibility = 17 |
10 | | - |
11 | | -group 'org.wiremock.integrations' |
| 5 | +allprojects { |
| 6 | + javaExtension { |
| 7 | + javaVersion = 17 |
| 8 | + } |
12 | 9 |
|
13 | | -jar { |
14 | | - manifest { |
15 | | - attributes 'name': project.name |
16 | | - attributes 'Automatic-Module-Name': project.group + "." + project.name |
| 10 | + tasks.withType(Test).configureEach { |
| 11 | + useJUnitPlatform() |
17 | 12 | } |
18 | 13 | } |
19 | 14 |
|
20 | | -// Because older version is set in wiremock-extension-convention |
21 | | -def wiremockVersion = "3.13.1" |
| 15 | +releaseExtension { |
| 16 | + nexusUsernameEnvOrProp = "OSSRH_USERNAME" |
| 17 | + nexusPasswordEnvOrProp = "OSSRH_TOKEN" |
| 18 | +} |
22 | 19 |
|
23 | | -configurations { |
24 | | - all*.exclude group: 'org.eclipse.jetty', module: 'jetty-servlet' |
25 | | - all*.exclude group: 'org.eclipse.jetty', module: 'jetty-servlets' |
26 | | - all*.exclude group: 'org.eclipse.jetty', module: 'jetty-webapp' |
27 | | - all*.exclude group: 'org.eclipse.jetty.http2', module: 'http2-server' |
| 20 | +signExtension { |
| 21 | + signingKeyEnvOrProp = "OSSRH_GPG_SECRET_KEY" |
| 22 | + signingPasswordEnvOrProp = "OSSRH_GPG_SECRET_KEY_PASSWORD" |
28 | 23 | } |
29 | 24 |
|
30 | | -dependencies { |
31 | | - implementation platform("org.eclipse.jetty:jetty-bom:12.0.15") |
32 | | - api "org.wiremock:wiremock-jetty12:${wiremockVersion}" |
33 | | - api "org.springframework.boot:spring-boot-test:3.4.1" |
34 | | - api "org.springframework:spring-test:6.1.13" |
35 | | - api "org.slf4j:slf4j-api:2.0.16" |
36 | | - api 'org.junit.jupiter:junit-jupiter-api:5.11.2' |
37 | | - |
38 | | - testImplementation "org.wiremock:wiremock-jetty12:${wiremockVersion}" |
39 | | - testImplementation "org.springframework.boot:spring-boot-starter-test:3.4.1" |
40 | | - testImplementation 'org.assertj:assertj-core:3.27.4' |
41 | | - testImplementation platform('org.junit:junit-bom:5.11.2') |
42 | | - testImplementation 'org.junit.jupiter:junit-jupiter' |
43 | | - testImplementation 'org.junit.platform:junit-platform-launcher' |
44 | | - testImplementation 'io.rest-assured:rest-assured:5.5.0' |
45 | | - testImplementation 'io.rest-assured:rest-assured:5.5.0' |
46 | | - testImplementation "org.springframework.boot:spring-boot-starter-web:3.4.1" |
47 | | - testImplementation 'io.cucumber:cucumber-java:7.20.1' |
48 | | - testImplementation 'io.cucumber:cucumber-spring:7.20.1' |
49 | | - testImplementation 'io.cucumber:cucumber-junit-platform-engine:7.20.1' |
50 | | - testImplementation 'org.junit.platform:junit-platform-suite:1.11.4' |
51 | | - testImplementation 'org.assertj:assertj-core:3.27.4' |
52 | | - |
53 | | - constraints { |
54 | | - implementation('org.apache.commons:commons-compress:1.26.0') { |
55 | | - because 'version 1.24.0 has a vulnerability' |
| 25 | +project("wiremock-spring-boot", { |
| 26 | + dependencies { |
| 27 | + implementation platform("org.eclipse.jetty:jetty-bom:12.1.3") |
| 28 | + implementation "org.eclipse.jetty.ee10:jetty-ee10-bom:12.1.3" |
| 29 | + api "org.wiremock:wiremock-jetty12:3.13.1" |
| 30 | + api "org.springframework.boot:spring-boot-test:3.5.7" |
| 31 | + api "org.springframework:spring-test:6.2.12" |
| 32 | + api "org.slf4j:slf4j-api:2.0.17" |
| 33 | + api "org.junit.jupiter:junit-jupiter-api:6.0.1" |
| 34 | + |
| 35 | + testImplementation "org.wiremock:wiremock-jetty12:3.13.1" |
| 36 | + testImplementation "org.springframework.boot:spring-boot-starter-test:3.5.7" |
| 37 | + testImplementation "org.assertj:assertj-core:3.27.6" |
| 38 | + testImplementation platform("org.junit:junit-bom:6.0.1") |
| 39 | + testImplementation 'org.junit.jupiter:junit-jupiter' |
| 40 | + testImplementation 'org.junit.platform:junit-platform-launcher' |
| 41 | + testImplementation "io.rest-assured:rest-assured:5.5.6" |
| 42 | + testImplementation "io.rest-assured:rest-assured:5.5.6" |
| 43 | + testImplementation "org.springframework.boot:spring-boot-starter-web:3.5.7" |
| 44 | + testImplementation "io.cucumber:cucumber-java:7.31.0" |
| 45 | + testImplementation "io.cucumber:cucumber-spring:7.31.0" |
| 46 | + testImplementation "io.cucumber:cucumber-junit-platform-engine:7.31.0" |
| 47 | + testImplementation "org.junit.platform:junit-platform-suite:6.0.1" |
| 48 | + testImplementation "org.assertj:assertj-core:3.27.6" |
| 49 | + |
| 50 | + constraints { |
| 51 | + implementation('org.apache.commons:commons-compress:1.26.0') { |
| 52 | + because 'version 1.24.0 has a vulnerability' |
| 53 | + } |
56 | 54 | } |
57 | 55 | } |
58 | | -} |
| 56 | +}) |
| 57 | + |
| 58 | +project("wiremock-spring-boot-standalone", { |
| 59 | + apply plugin: 'se.bjurr.gradle.shadow' |
| 60 | + |
| 61 | + shadowJar { |
| 62 | + relocate "org.wiremock", 'wiremock.org.wiremock' |
| 63 | + relocate "org", 'wiremock.org' |
| 64 | + relocate "com.google", 'wiremock.com' |
| 65 | + relocate "net.minidev", 'wiremock.net' |
| 66 | + relocate "jakarta.servlet", "wiremock.jakarta" |
| 67 | + relocate "joptsimple", "wiremock.joptsimple" |
| 68 | + exclude 'joptsimple/HelpFormatterMessages.properties' |
| 69 | + |
| 70 | + mergeServiceFiles() |
| 71 | + |
| 72 | + exclude 'META-INF/maven/**' |
| 73 | + exclude 'META-INF/versions/17/**' |
| 74 | + exclude 'META-INF/versions/21/**' |
| 75 | + exclude 'META-INF/versions/22/**' |
| 76 | + exclude 'module-info.class' |
| 77 | + exclude 'handlebars-*.js' |
| 78 | + } |
| 79 | + |
| 80 | + dependencies { |
| 81 | + implementation project(":wiremock-spring-boot") |
| 82 | + } |
| 83 | +}) |
0 commit comments