### Question:
HomeController { @RequestMapping(value = "/", method = RequestMethod.GET) public String home(Model model) { logger.info("Welcome home!"); model.addAttribute("controllerMessage", "This is the message from the controller!"); return "home"; }  @RequestMapping(value = "/", method = RequestMethod.GET) String home(Model model);  }### Answer:
@Test public void testController() { HomeController controller = new HomeController(); Model model = new ExtendedModelMap(); Assert.assertEquals("home",controller.home(model)); Object message = model.asMap().get("controllerMessage"); Assert.assertEquals("This is the message from the controller!",message); }