Skip to content

Commit 4c38893

Browse files
committed
chore(deps)!: WireMock 4
1 parent 3c91092 commit 4c38893

File tree

2 files changed

+19
-38
lines changed

2 files changed

+19
-38
lines changed

build.gradle

Lines changed: 18 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -28,45 +28,26 @@ jar {
2828
}
2929
}
3030

31-
// Because older version is set in wiremock-extension-convention
32-
def wiremockVersion = "3.13.0"
33-
34-
configurations {
35-
all*.exclude group: 'org.eclipse.jetty', module: 'jetty-servlet'
36-
all*.exclude group: 'org.eclipse.jetty', module: 'jetty-servlets'
37-
all*.exclude group: 'org.eclipse.jetty', module: 'jetty-webapp'
38-
all*.exclude group: 'org.eclipse.jetty.http2', module: 'http2-server'
39-
}
40-
4131
dependencies {
42-
implementation platform("org.eclipse.jetty:jetty-bom:12.0.15")
43-
api "org.wiremock:wiremock-jetty12:${wiremockVersion}"
44-
45-
api "org.springframework.boot:spring-boot-test:3.4.1"
46-
api "org.springframework:spring-test:6.1.13"
47-
api "org.slf4j:slf4j-api:2.0.16"
48-
api 'org.junit.jupiter:junit-jupiter-api:5.11.2'
49-
50-
testImplementation "org.wiremock:wiremock-jetty12:${wiremockVersion}"
51-
testImplementation "org.springframework.boot:spring-boot-starter-test:3.4.1"
52-
testImplementation 'org.assertj:assertj-core:3.26.3'
53-
testImplementation platform('org.junit:junit-bom:5.11.2')
32+
api "org.wiremock:wiremock-standalone:4.0.0-beta.9"
33+
/**
34+
* We don't want a user to accidentally test with another version of these dependencies.
35+
* Intentionally using compileOnly to avoid them being transitive.
36+
*/
37+
compileOnly 'org.springframework.boot:spring-boot-test:3.5.0'
38+
compileOnly 'org.junit.jupiter:junit-jupiter-api:5.12.2'
39+
compileOnly 'org.slf4j:slf4j-api:2.0.17'
40+
41+
testImplementation 'org.springframework.boot:spring-boot-starter-web:3.5.0'
42+
testImplementation 'org.springframework.boot:spring-boot-test:3.5.0'
43+
testImplementation 'org.slf4j:slf4j-api:2.0.17'
44+
testImplementation 'org.assertj:assertj-core:3.27.3'
5445
testImplementation 'org.junit.jupiter:junit-jupiter'
55-
testImplementation 'org.junit.platform:junit-platform-launcher'
56-
testImplementation 'io.rest-assured:rest-assured:5.5.0'
57-
testImplementation 'io.rest-assured:rest-assured:5.5.0'
58-
testImplementation "org.springframework.boot:spring-boot-starter-web:3.4.1"
59-
testImplementation 'io.cucumber:cucumber-java:7.20.1'
60-
testImplementation 'io.cucumber:cucumber-spring:7.20.1'
61-
testImplementation 'io.cucumber:cucumber-junit-platform-engine:7.20.1'
62-
testImplementation 'org.junit.platform:junit-platform-suite:1.11.4'
63-
testImplementation 'org.assertj:assertj-core:3.26.3'
64-
65-
constraints {
66-
implementation('org.apache.commons:commons-compress:1.26.0') {
67-
because 'version 1.24.0 has a vulnerability'
68-
}
69-
}
46+
testImplementation 'io.rest-assured:rest-assured:5.5.5'
47+
testImplementation 'io.cucumber:cucumber-java:7.23.0'
48+
testImplementation 'io.cucumber:cucumber-spring:7.23.0'
49+
testImplementation 'io.cucumber:cucumber-junit-platform-engine:7.23.0'
50+
testImplementation 'org.junit.platform:junit-platform-suite:1.12.2'
7051
}
7152

7253
// Not using shadowJar, but currently not possible to disable in wiremock-extension-convention

src/test/java/usecases/NotEnabledTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,11 @@
66
import static org.junit.jupiter.api.Assertions.assertThrows;
77

88
import com.github.tomakehurst.wiremock.client.WireMock;
9-
import org.apache.hc.client5.http.HttpHostConnectException;
109
import org.junit.jupiter.api.Test;
1110
import org.springframework.beans.factory.annotation.Autowired;
1211
import org.springframework.boot.test.context.SpringBootTest;
1312
import org.springframework.core.env.Environment;
13+
import wiremock.org.apache.hc.client5.http.HttpHostConnectException;
1414

1515
@SpringBootTest
1616
class NotEnabledTest {

0 commit comments

Comments
 (0)