Skip to content

Commit f11c030

Browse files
ahrytsiuksnicoll
authored andcommitted
Align TestRestTemplate Javadoc with documentation
See gh-21318
1 parent 15cd0f8 commit f11c030

File tree

1 file changed

+8
-4
lines changed
  • spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/web/client

1 file changed

+8
-4
lines changed

spring-boot-project/spring-boot-test/src/main/java/org/springframework/boot/test/web/client/TestRestTemplate.java

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -65,10 +65,14 @@
6565
* {@link #getRestTemplate()}.
6666
* <p>
6767
* If you are using the
68-
* {@link org.springframework.boot.test.context.SpringBootTest @SpringBootTest}
69-
* annotation, a {@link TestRestTemplate} is automatically available and can be
70-
* {@code @Autowired} into your test. If you need customizations (for example to adding
71-
* additional message converters) use a {@link RestTemplateBuilder} {@code @Bean}.
68+
* {@link org.springframework.boot.test.context.SpringBootTest @SpringBootTest} annotation
69+
* with
70+
* {@link org.springframework.boot.test.context.SpringBootTest.WebEnvironment#RANDOM_PORT
71+
* WebEnvironment.RANDOM_PORT} or
72+
* {@link org.springframework.boot.test.context.SpringBootTest.WebEnvironment#DEFINED_PORT
73+
* WebEnvironment.DEFINED_PORT}, a {@link TestRestTemplate} is automatically available and
74+
* can be {@code @Autowired} into your test. If you need customizations (for example to
75+
* adding additional message converters) use a {@link RestTemplateBuilder} {@code @Bean}.
7276
*
7377
* @author Dave Syer
7478
* @author Phillip Webb

0 commit comments

Comments
 (0)