mirror of
https://github.com/spring-projects/spring-framework.git
synced 2026-09-22 05:49:04 +00:00
Polishing contribution
See gh-37099
This commit is contained in:
+4
-4
@@ -194,14 +194,14 @@ class ServerHttpRequestTests {
|
||||
assertThat(mutated.getURI().getRawPath()).isEqualTo("/other/path");
|
||||
}
|
||||
|
||||
@Test
|
||||
@Test // gh-37099
|
||||
void mutateContextPathToNull() throws Exception {
|
||||
ServerHttpRequest request = createRequest("/context/path", "/context");
|
||||
|
||||
ServerHttpRequest mutated = request.mutate().contextPath(null).build();
|
||||
ServerHttpRequest mutated = request.mutate().contextPath(null).path("/path").build();
|
||||
assertThat(mutated.getPath().contextPath().value()).isEmpty();
|
||||
assertThat(mutated.getPath().pathWithinApplication().value()).isEqualTo("/context/path");
|
||||
assertThat(mutated.getURI().getRawPath()).isEqualTo("/context/path");
|
||||
assertThat(mutated.getPath().pathWithinApplication().value()).isEqualTo("/path");
|
||||
assertThat(mutated.getURI().getRawPath()).isEqualTo("/path");
|
||||
}
|
||||
|
||||
@Test
|
||||
|
||||
Reference in New Issue
Block a user