SampleController { @GetMapping("/hello-template") public String hello(Model model) { model.addAttribute("name", "siyoon"); return "hello-templateEngine"; }  @GetMapping("/hello-template") String hello(Model model);  }
@Test public void helloTest() throws Exception { mockMvc.perform(get("/hello-template")) .andExpect(status().isOk()) .andExpect(view().name("hello-templateEngine")) .andDo(print()) .andExpect(model().attribute("name", "siyoon")); }