Fix checkstyle violations
This commit is contained in:
@@ -118,7 +118,7 @@ public class HandlerMethodMappingTests {
|
|||||||
this.mapping.registerMapping("/fo?", this.handler, this.method2);
|
this.mapping.registerMapping("/fo?", this.handler, this.method2);
|
||||||
|
|
||||||
MockServerWebExchange exchange = MockServerWebExchange.from(
|
MockServerWebExchange exchange = MockServerWebExchange.from(
|
||||||
MockServerHttpRequest.options("http://example.org/foo")
|
MockServerHttpRequest.options("https://example.org/foo")
|
||||||
.header(HttpHeaders.ORIGIN, "https://domain.com")
|
.header(HttpHeaders.ORIGIN, "https://domain.com")
|
||||||
.header(HttpHeaders.ACCESS_CONTROL_REQUEST_METHOD, "GET"));
|
.header(HttpHeaders.ACCESS_CONTROL_REQUEST_METHOD, "GET"));
|
||||||
|
|
||||||
@@ -133,7 +133,7 @@ public class HandlerMethodMappingTests {
|
|||||||
this.mapping.registerMapping("/fo?", this.handler, this.handler.getClass().getMethod("corsHandlerMethod"));
|
this.mapping.registerMapping("/fo?", this.handler, this.handler.getClass().getMethod("corsHandlerMethod"));
|
||||||
|
|
||||||
MockServerWebExchange exchange = MockServerWebExchange.from(
|
MockServerWebExchange exchange = MockServerWebExchange.from(
|
||||||
MockServerHttpRequest.options("http://example.org/foo")
|
MockServerHttpRequest.options("https://example.org/foo")
|
||||||
.header(HttpHeaders.ORIGIN, "https://domain.com")
|
.header(HttpHeaders.ORIGIN, "https://domain.com")
|
||||||
.header(HttpHeaders.ACCESS_CONTROL_REQUEST_METHOD, "GET"));
|
.header(HttpHeaders.ACCESS_CONTROL_REQUEST_METHOD, "GET"));
|
||||||
|
|
||||||
@@ -216,7 +216,7 @@ public class HandlerMethodMappingTests {
|
|||||||
CrossOrigin crossOrigin = AnnotatedElementUtils.findMergedAnnotation(method, CrossOrigin.class);
|
CrossOrigin crossOrigin = AnnotatedElementUtils.findMergedAnnotation(method, CrossOrigin.class);
|
||||||
if (crossOrigin != null) {
|
if (crossOrigin != null) {
|
||||||
CorsConfiguration corsConfig = new CorsConfiguration();
|
CorsConfiguration corsConfig = new CorsConfiguration();
|
||||||
corsConfig.setAllowedOrigins(Collections.singletonList("http://domain.com"));
|
corsConfig.setAllowedOrigins(Collections.singletonList("https://domain.com"));
|
||||||
return corsConfig;
|
return corsConfig;
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
|
|||||||
@@ -306,7 +306,7 @@ public class HandlerMethodMappingTests {
|
|||||||
CrossOrigin crossOrigin = AnnotatedElementUtils.findMergedAnnotation(method, CrossOrigin.class);
|
CrossOrigin crossOrigin = AnnotatedElementUtils.findMergedAnnotation(method, CrossOrigin.class);
|
||||||
if (crossOrigin != null) {
|
if (crossOrigin != null) {
|
||||||
CorsConfiguration corsConfig = new CorsConfiguration();
|
CorsConfiguration corsConfig = new CorsConfiguration();
|
||||||
corsConfig.setAllowedOrigins(Collections.singletonList("http://domain.com"));
|
corsConfig.setAllowedOrigins(Collections.singletonList("https://domain.com"));
|
||||||
return corsConfig;
|
return corsConfig;
|
||||||
}
|
}
|
||||||
return null;
|
return null;
|
||||||
|
|||||||
Reference in New Issue
Block a user