Skip to content

Commit b135cbe

Browse files
committed
Merge branch '5.3.x'
2 parents 0ad558d + c942c8d commit b135cbe

File tree

2 files changed

+13
-13
lines changed

2 files changed

+13
-13
lines changed

src/docs/asciidoc/core/core-beans.adoc

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1368,7 +1368,7 @@ The following example shows the corresponding `ExampleBean` class:
13681368
}
13691369
}
13701370
----
1371-
[source,java,indent=0,subs="verbatim,quotes",role="secondary"]
1371+
[source,kotlin,indent=0,subs="verbatim,quotes",role="secondary"]
13721372
.Kotlin
13731373
----
13741374
class ExampleBean(
@@ -4727,7 +4727,7 @@ as the following example shows:
47274727
----
47284728
class SimpleMovieLister {
47294729
4730-
@Autowired
4730+
@set:Autowired
47314731
lateinit var movieFinder: MovieFinder
47324732
47334733
// ...
@@ -5880,7 +5880,7 @@ named `movieFinder` injected into its setter method:
58805880
----
58815881
class SimpleMovieLister {
58825882
5883-
@Resource
5883+
@set:Resource
58845884
private lateinit var movieFinder: MovieFinder
58855885
58865886
}
@@ -7247,11 +7247,11 @@ preceding example:
72477247
class SimpleMovieLister {
72487248
72497249
@Inject
7250-
lateinit var movieFinder: MovieFinder
7250+
lateinit var movieFinder: Provider<MovieFinder>
72517251
72527252
72537253
fun listMovies() {
7254-
movieFinder.findMovies(...)
7254+
movieFinder.get().findMovies(...)
72557255
// ...
72567256
}
72577257
}
@@ -9594,7 +9594,7 @@ of creating a custom composed annotation. The following example defines a custom
95949594
[source,kotlin,indent=0,subs="verbatim,quotes",role="secondary"]
95959595
.Kotlin
95969596
----
9597-
@Target(AnnotationTarget.TYPE)
9597+
@Target(AnnotationTarget.CLASS)
95989598
@Retention(AnnotationRetention.RUNTIME)
95999599
@Profile("production")
96009600
annotation class Production

src/docs/asciidoc/testing.adoc

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -2522,7 +2522,7 @@ listeners. The following listing demonstrates this style of configuration:
25222522
}
25232523
----
25242524

2525-
[source,java,indent=0,subs="verbatim,quotes",role="secondary"]
2525+
[source,kotlin,indent=0,subs="verbatim,quotes",role="secondary"]
25262526
.Kotlin
25272527
----
25282528
@ContextConfiguration
@@ -7366,7 +7366,7 @@ no other expectations will be asserted.
73667366
import org.springframework.test.web.servlet.get
73677367
73687368
mockMvc.get("/accounts/1").andExpect {
7369-
status().isOk()
7369+
status { isOk() }
73707370
}
73717371
----
73727372

@@ -7414,7 +7414,7 @@ The following test asserts that binding or validation failed:
74147414
import org.springframework.test.web.servlet.post
74157415
74167416
mockMvc.post("/persons").andExpect {
7417-
status().isOk()
7417+
status { isOk() }
74187418
model {
74197419
attributeHasErrors("person")
74207420
}
@@ -7442,7 +7442,7 @@ request. You can do so as follows, where `print()` is a static import from
74427442
mockMvc.post("/persons").andDo {
74437443
print()
74447444
}.andExpect {
7445-
status().isOk()
7445+
status { isOk() }
74467446
model {
74477447
attributeHasErrors("person")
74487448
}
@@ -7472,7 +7472,7 @@ other expectations, as the following example shows:
74727472
[source,kotlin,indent=0,subs="verbatim,quotes",role="secondary"]
74737473
.Kotlin
74747474
----
7475-
var mvcResult = mockMvc.post("/persons").andExpect { status().isOk() }.andReturn()
7475+
var mvcResult = mockMvc.post("/persons").andExpect { status { isOk() } }.andReturn()
74767476
// ...
74777477
----
74787478

@@ -7592,7 +7592,7 @@ or reactive type such as Reactor `Mono`:
75927592
@Test
75937593
fun test() {
75947594
var mvcResult = mockMvc.get("/path").andExpect {
7595-
status().isOk() // <1>
7595+
status { isOk() } // <1>
75967596
request { asyncStarted() } // <2>
75977597
// TODO Remove unused generic parameter
75987598
request { asyncResult<Nothing>("body") } // <3>
@@ -7601,7 +7601,7 @@ or reactive type such as Reactor `Mono`:
76017601
76027602
mockMvc.perform(asyncDispatch(mvcResult)) // <4>
76037603
.andExpect {
7604-
status().isOk() // <5>
7604+
status { isOk() } // <5>
76057605
content().string("body")
76067606
}
76077607
}

0 commit comments

Comments
 (0)