What do I need for this nice block syntax seen at ...
# spring
p
What do I need for this nice block syntax seen at https://medium.com/backyard-programmers/kotlin-spring-boot-unit-testing-integration-testing-with-junit5-and-mockk-a2977bbe5711 I only can say status().isOk(), and I cannot use the content block.
t
I think it’s just imports,
Copy code
import org.springframework.test.web.servlet.get
at least, with both spring boot 2.7 and 3.1 (currently migrating) I don’t think I needed any extra library
I get them from
spring-test
c
The definition is
org.springframework.test.web.servlet.result.MockMvcResultMatchers#content
It exists in the jar
spring-test-6.0.10.jar
With gradle dependency
org.springframework:spring-test:6.0.10
p
Upgraded my deps to
kotlin("plugin.spring") version "1.8.22"
solved it ¯\_(ツ)_/¯