diff --git a/src/docs/asciidoc/testing-webtestclient.adoc b/src/docs/asciidoc/testing-webtestclient.adoc index 0ead66eeb1..8023e9790e 100644 --- a/src/docs/asciidoc/testing-webtestclient.adoc +++ b/src/docs/asciidoc/testing-webtestclient.adoc @@ -8,9 +8,10 @@ to any server over an HTTP connection. It can also bind directly to WebFlux appl with <> objects, without the need for an HTTP server. -[NOTE] +[TIP] ==== -`WebTestClient` is not usable yet in Kotlin, see <> for more details. +Kotlin users, please see <> for +important information on using the `WebTestClient` in Kotlin. ==== diff --git a/src/docs/asciidoc/web-reactive.adoc b/src/docs/asciidoc/web-reactive.adoc index b3da2ba2e4..083db2702a 100644 --- a/src/docs/asciidoc/web-reactive.adoc +++ b/src/docs/asciidoc/web-reactive.adoc @@ -25,6 +25,7 @@ include::web/webflux-websocket.adoc[leveloffset=+1] [[webflux-test]] == Testing +[.small]#<># The `spring-test` module provides mock implementations of `ServerHttpRequest`, `ServerHttpResponse`, and `ServerWebExchange`. diff --git a/src/docs/asciidoc/web/webmvc-test.adoc b/src/docs/asciidoc/web/webmvc-test.adoc index 79921f10df..eb96bebb5c 100644 --- a/src/docs/asciidoc/web/webmvc-test.adoc +++ b/src/docs/asciidoc/web/webmvc-test.adoc @@ -1,5 +1,6 @@ [[testing]] = Testing +[.small]#<># @@ -26,11 +27,12 @@ See <> for more detail [[testing-mockmvc]] -== Spring MVC Tests +== Spring MVC Test (MockMvc) -`spring-test` provides an integration test framework for testing annotated controllers -through the `DispatcherServlet`, complete with Spring MVC infrastructure, but without an -HTTP server. See <> for more details. +`spring-test` provides a framework for testing annotated controllers through the +`DispatcherServlet`, i.e. supporting annotations and complete with Spring MVC +infrastructure, but without an HTTP server. +See <> for more details. @@ -41,3 +43,13 @@ HTTP server. See <> for `spring-test` provides a `MockRestServiceServer` that can be used as a mock server for testing client-side code that internally uses the `RestTemplate`. See <> for more details. + + + + +[[testing-webtestclient]] +== WebTestClient + +`spring-test` provides a dedicated `WebTestClient` for end-to-end integration testing. +`WebTestClient` can connect to any server over an HTTP connection. It is non-blocking, +reactive client and well suited for testing asynchronous and streaming scenarios.