### Question:
RestApiController { @PostMapping("/qq/{qq}") @BussinessLog(value = "获取QQ信息", platform = PlatformEnum.WEB) public ResponseVO qq(@PathVariable("qq") String qq) { if (StringUtils.isEmpty(qq)) { return ResultUtil.error(""); } Map<String, String> resultMap = new HashMap<>(4); String nickname = "匿名"; String json = RestClientUtil.get("http: if (!StringUtils.isEmpty(json)) { try { json = json.replaceAll("portraitCallBack|\\\\s*|\\t|\\r|\\n", ""); json = json.substring(1, json.length() - 1); log.info(json); JSONObject object = JSONObject.parseObject(json); JSONArray array = object.getJSONArray(qq); nickname = array.getString(6); } catch (Exception e) { log.error("通过QQ号获取用户昵称发生异常", e); } } resultMap.put("avatar", "https: resultMap.put("nickname", nickname); resultMap.put("email", qq + "@qq.com"); resultMap.put("url", "https: return ResultUtil.success(null, resultMap); }  @PostMapping("/autoLink") @BussinessLog(value = "自助申请友链", platform = PlatformEnum.WEB) ResponseVO autoLink(@Validated Link link, BindingResult bindingResult); @PostMapping("/qq/{qq}") @BussinessLog(value = "获取QQ信息", platform = PlatformEnum.WEB) ResponseVO qq(@PathVariable("qq") String qq); @PostMapping("/comments") @BussinessLog(value = "评论列表", platform = PlatformEnum.WEB, save = false) ResponseVO comments(CommentConditionVO vo); @PostMapping("/comment") @BussinessLog(value = "发表评论", platform = PlatformEnum.WEB) ResponseVO comment(Comment comment); @PostMapping("/doSupport/{id}") @BussinessLog(value = "点赞评论{1}", platform = PlatformEnum.WEB) ResponseVO doSupport(@PathVariable("id") Long id); @PostMapping("/doOppose/{id}") @BussinessLog(value = "点踩评论{1}", platform = PlatformEnum.WEB) ResponseVO doOppose(@PathVariable("id") Long id); @PostMapping("/doPraise/{id}") @BussinessLog(value = "点赞文章{1}", platform = PlatformEnum.WEB) ResponseVO doPraise(@PathVariable("id") Long id); @PostMapping("/listNotice") @BussinessLog(value = "公告列表", platform = PlatformEnum.WEB, save = false) ResponseVO listNotice();  }### Answer:
@Test public void qq() throws Exception { MvcResult result = mvc.perform(MockMvcRequestBuilders.post(host + "/api/qq/843977358") .contentType(MediaType.APPLICATION_FORM_URLENCODED_VALUE)) .andExpect(MockMvcResultMatchers.status().isOk()) .andDo(MockMvcResultHandlers.print()) .andReturn(); System.out.println(result.getResponse().getContentAsString()); }