Skip to content

Commit 1f128e8

Browse files
committed
fix test
1 parent 0287e83 commit 1f128e8

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

springdoc-openapi-starter-webflux-ui/src/test/java/test/org/springdoc/ui/app32/SpringDocBehindProxyBasePathTest.java

+5-5
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@
3939

4040

4141
@SpringBootTest(webEnvironment = WebEnvironment.DEFINED_PORT,
42-
properties = { "spring.webflux.base-path=/test",
43-
"server.forward-headers-strategy=framework",
42+
properties = { //"spring.webflux.base-path=/test",
43+
"server.forward-headers-strategy=native",
4444
"server.port=9318",
4545
"springdoc.swagger-ui.path=/documentation/swagger-ui.html",
4646
"springdoc.api-docs.path=/documentation/v3/api-docs",
@@ -64,17 +64,17 @@ void init() {
6464

6565
@Test
6666
public void testIndex() throws Exception {
67-
HttpStatusCode httpStatusMono = webClient.get().uri("/test/documentation/swagger-ui.html")
67+
HttpStatusCode httpStatusMono = webClient.get().uri("/documentation/swagger-ui.html")
6868
.header("X-Forwarded-Prefix", X_FORWARD_PREFIX)
6969
.exchangeToMono(clientResponse -> Mono.just(clientResponse.statusCode())).block();
7070
assertThat(httpStatusMono).isEqualTo(HttpStatus.FOUND);
7171

72-
httpStatusMono = webClient.get().uri("/test/documentation/webjars-pref/swagger-ui/index.html")
72+
httpStatusMono = webClient.get().uri("/documentation/webjars-pref/swagger-ui/index.html")
7373
.header("X-Forwarded-Prefix", X_FORWARD_PREFIX)
7474
.exchangeToMono(clientResponse -> Mono.just(clientResponse.statusCode())).block();
7575
assertThat(httpStatusMono).isEqualTo(HttpStatus.OK);
7676

77-
String contentAsString = webClient.get().uri("/test/documentation/v3/api-docs/swagger-config")
77+
String contentAsString = webClient.get().uri("/documentation/v3/api-docs/swagger-config")
7878
.header("X-Forwarded-Prefix", X_FORWARD_PREFIX)
7979
.retrieve()
8080
.bodyToMono(String.class).block();

0 commit comments

Comments
 (0)