Skip to content

Commit

Permalink
Replaced deprecated HttpMethod.resolve (rest-assured#1760)
Browse files Browse the repository at this point in the history
  • Loading branch information
felhag committed Mar 28, 2024
1 parent 034ebfb commit a24a6c0
Showing 1 changed file with 1 addition and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -145,11 +145,7 @@ public WebTestClientResponse request(String method, Function<UriBuilder, URI> ur

private HttpMethod toValidHttpMethod(String method) {
String httpMethodAsString = notNull(trimToNull(method), "HTTP Method");
HttpMethod httpMethod = HttpMethod.resolve(httpMethodAsString.toUpperCase());
if (httpMethod == null) {
throw new IllegalArgumentException("HTTP method '" + method + "' is not supported by WebTestClient");
}
return httpMethod;
return HttpMethod.valueOf(httpMethodAsString.toUpperCase());
}

@Override
Expand Down

0 comments on commit a24a6c0

Please sign in to comment.