MainController { @GetMapping("/") public String index(Model model) { model.addAttribute("content", systemService.getIndex()); return "index"; }  @GetMapping("/") String index(Model model); @GetMapping("faq") String faq(); @GetMapping("findpassword") String findPassword(); @GetMapping({"registerpage", "register"}) String registerPage();  }
@Test public void testIndex() throws Exception { log.info("index"); MvcResult result = mvc.perform(get("/")) .andExpect(status().isOk()) .andExpect(view().name("index")) .andReturn(); }