@Test
public void testSave() throws Exception {

    Menu menu = new Menu();
    menu.setName("测试");
    menu.setNumber("HOMEasdad");
    menu.setPath("/dashboardadasd");
    menu.setType(MenuType.CONTENT);
    menu.setOrderNum(6);
    menu.setComponent("@layout/index-------");
    MenuMeta meta = new MenuMeta();
    menu.setMeta(meta);
    String content = objectMapper.writeValueAsString(menu);
    String result = mockMvc.perform(post("/sys/menu")
            .header(HttpHeaders.AUTHORIZATION, String.join(" ", accessToken.getTokenType(), accessToken.getValue()))
            .content(content) // @RequestBody 解析
            .contentType(MediaType.APPLICATION_JSON_UTF8) // @RequestBody 解
              .param("xxx", "xxx")// @RequestParam 解析
              .contentType(MediaType.APPLICATION_FORM_URLENCODED) // @RequestParam 解析
            .accept(MediaType.APPLICATION_JSON_UTF8)) // 响应类型
            .andExpect(status().isOk())
            .andExpect(jsonPath("$.data.id").isNotEmpty())
            .andReturn().getResponse().getContentAsString();
    log.info("{}",result);
}