Class AbstractWebMvcTest
java.lang.Object
io.microsphere.spring.test.webmvc.AbstractWebMvcTest
@Disabled
@WebAppConfiguration
@SpringJUnitConfig(classes={TestController.class,RouterFunctionTestConfig.class})
@EnableWebMvc
public abstract class AbstractWebMvcTest
extends Object
Abstract class for WebMVC testing
- Since:
- 1.0.0
- Author:
- Mercy
- See Also:
-
EnableWebMvc
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
context
@Autowired protected org.springframework.web.context.ConfigurableWebApplicationContext context -
mockMvc
protected org.springframework.test.web.servlet.MockMvc mockMvc
-
-
Constructor Details
-
AbstractWebMvcTest
public AbstractWebMvcTest()
-
-
Method Details
-
setUp
@BeforeEach protected void setUp() -
testWebEndpoints
Test the Web Endpoints -
testHelloWorld
- Throws:
Exception- If failed to executeMockMvc.perform(RequestBuilder)
-
testGreeting
- Throws:
Exception- If failed to executeMockMvc.perform(RequestBuilder)
-
testUser
- Throws:
Exception- If failed to executeMockMvc.perform(RequestBuilder)
-
testError
protected void testError()- Throws:
Exception- If failed to executeMockMvc.perform(RequestBuilder)
-
testResponseEntity
- Throws:
Exception- If failed to executeMockMvc.perform(RequestBuilder)
-
testView
- Throws:
Exception- If failed to executeMockMvc.perform(RequestBuilder)
-
testUpdatePerson
Test RouterFunctionTestConfig#nestedPersonRouterFunction(PersonHandler)- Throws:
Exception- If failed to executeMockMvc.perform(RequestBuilder)
-