1
I am following the following article: Introduction To Spring MVC Test Framework
I have the following code:
this.mockMvc.perform(get("/product/1"))
.andExpect(status().isOk().
.alwaysExpect(content().contentType("application/json;charset=UTF-8")));
And the class has these notes:
@RunWith(SpringJUnit4ClassRunner.class)
@WebAppConfiguration
@ContextConfiguration(locations = "classpath*:/spring/spring*.xml")
However it is not finding the methods get()
, status()
and content()
, where these methods are imported?
Thank you very much for your reply, it worked here +1
– Giancarlo Abel Giulian