UserController { @RequestMapping(value = "/group/users") public ServiceResult<List<LoginUser>> findGroupUserList(@RequestParam(value = "groupId", defaultValue = "0") Long groupId) throws Exception { return ServiceResult.success(loginUserDao.getUserByGroupId(groupId)); }  @RequestMapping(value = "/group/users") ServiceResult<List<LoginUser>> findGroupUserList(@RequestParam(value = "groupId", defaultValue = "0") Long groupId); @RequestMapping(value = "/list", method = RequestMethod.POST) ServiceResult<ListResult<LoginUserView>> findUserPageList(@RequestBody Paging<LoginUser> paging); @RequestMapping(value = "/getWorkInfo") ServiceResult<LoginUser> getWorkInfo(@RequestParam(value = "name", defaultValue = "") String name, @CurrentUser LoginUser user); @RequestMapping(value = "/add", method = RequestMethod.POST) ServiceResult<String> addUser(@Validated(AddUser.class) @RequestBody LoginUser user, @CurrentUser LoginUser currentUser, Errors errors); @RequestMapping(value = "/update", method = RequestMethod.PUT) ServiceResult<String> update(@Validated(UpdateUser.class) @RequestBody LoginUser user, @CurrentUser LoginUser currentUser, Errors errors); @RequestMapping(value = "/delete", method = RequestMethod.DELETE) ServiceResult<String> delete(@Validated(DeleteUser.class) @RequestBody LoginUser user, @CurrentUser LoginUser currentUser, Errors errors); @RequestMapping("/buttons") ServiceResult getDataBaseButton(@CurrentUser LoginUser user);  }
@Test public void findGroupUserList() throws Exception { mockMvc.perform(MockMvcRequestBuilders.get("/user/group/users") .contentType(MediaType.APPLICATION_JSON_UTF8) .param("groupId", "1") .accept(MediaType.APPLICATION_JSON_UTF8)) .andExpect(MockMvcResultMatchers.status().isOk()) .andDo(MockMvcResultHandlers.print()); }