Code example for MockMvc

Methods: perform

0
    } 
 
    @Test 
    public void invalidPostsShowsErrors() throws Exception { 
        MockHttpServletRequestBuilder createPostRequest = getCreatePostRequest(); 
        mockMvc.perform(createPostRequest).andExpect(status().isOk()); 
    } 
 
} 
Connect your IDE to all the code out there  Get Codota for Java