spring-framework / org.springframework.test.web.client.match / MockRestRequestMatchers / requestToUriTemplate

requestToUriTemplate

open static fun requestToUriTemplate(expectedUri: String, vararg uriVars: Any): RequestMatcher

Variant of #requestTo(URI) that prepares the URI from a URI template plus optional variables via UriComponentsBuilder including encoding.

Parameters

expectedUri - the expected URI template

uriVars - zero or more URI variables to populate the expected URI

Return
the request matcher