Created
January 30, 2014 13:36
-
-
Save oak-tree/8708433 to your computer and use it in GitHub Desktop.
spring controller integration test
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
MvcResult result = (MvcResult) mockMvc.perform(post("/api/search/report/advanced").contentType(TestUtil.APPLICATION_JSON_UTF8) | |
.content(pageRequest.getBytes())) | |
.andExpect(status().isOk()) | |
.andExpect(content().contentType(TestUtil.APPLICATION_JSON_UTF8)) | |
.andExpect(jsonPath("$[0].page").value(page.intValue())) | |
.andExpect(jsonPath("$[0].page").exists()).andReturn(); | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment