> For the complete documentation index, see [llms.txt](https://jack80342.gitbook.io/spring-boot/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://jack80342.gitbook.io/spring-boot/iv.-spring-boot-features/43.-testing/43.3-testing-spring-boot-applications/43.3.20-using-spock-to-test-spring-boot-applications.md).

# 43.3.20 使用Spock测试Spring Boot应用

如果想使用Spock测试Spring Boot应用，你需要为应用添加Spock的`spock-spring`依赖。该依赖已将Spring测试框架集成进Spock。推荐使用Spock 1.1或之后的版本，以便获得关于Spock的Spring框架和Spring Boot的集成的大量改进。详细内容请查看[Spock的Spring模块的文档](http://spockframework.org/spock/docs/1.1/modules.html)。
