BAEL-3802: Upgrade spring-boot-testing to Spring Boot 2.2.2 (#8779)

This commit is contained in:
kwoyke 2020-02-29 21:19:47 +01:00 committed by GitHub
parent 2b9aea7aae
commit 36474ca59f
2 changed files with 6 additions and 4 deletions

View File

@ -132,7 +132,6 @@
<spock.version>1.2-groovy-2.4</spock.version>
<gmavenplus-plugin.version>1.6</gmavenplus-plugin.version>
<redis.version>0.7.2</redis.version>
<spring-boot.version>2.1.9.RELEASE</spring-boot.version>
</properties>
</project>

View File

@ -1,8 +1,10 @@
package com.baeldung.boot
import org.springframework.beans.factory.annotation.Autowired
import org.springframework.boot.autoconfigure.EnableAutoConfiguration
import org.springframework.boot.autoconfigure.security.servlet.SecurityAutoConfiguration
import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc
import org.springframework.boot.test.autoconfigure.web.servlet.WebMvcTest
import org.springframework.boot.test.context.SpringBootTest
import org.springframework.test.web.servlet.MockMvc
import org.springframework.test.web.servlet.request.MockMvcRequestBuilders
import org.springframework.test.web.servlet.result.MockMvcResultMatchers
@ -12,8 +14,9 @@ import spock.lang.Title
@Title("WebController Specification")
@Narrative("The Specification of the behaviour of the WebController. It can greet a person, change the name and reset it to 'world'")
@AutoConfigureMockMvc(secure=false)
@WebMvcTest()
@SpringBootTest
@AutoConfigureMockMvc
@EnableAutoConfiguration(exclude= SecurityAutoConfiguration.class)
class WebControllerTest extends Specification {
@Autowired