Skip to content

TestRestTemplate does not resolve relative links with java.net.URI parameter #7891

@shollander

Description

@shollander

According to the documentation, when using @SpringBootTest(webEnvironment=WebEnvironment.RANDOM_PORT) TestRestTemplate will resolve relative links to the running server.

This works when calling TestRestTemplate with a String parameter for the uri. When using the methods that take a java.net.URI I get org.apache.http.ProtocolException: Target host is not specified

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions