GroupSearchController extends AbstractFormController { @Override protected ModelAndView showForm(HttpServletRequest request, HttpServletResponse response, BindException errors) throws Exception { SearchCommand command = (SearchCommand) request.getSession().getAttribute("groupsSearchCommand"); if(command == null) { command = getDefaultCommand(); } command.setSelectedPageSize(CookieUtils.getPageSize(request)); return prepareSearchView(request, response, command, errors); } GroupSearchController(); @Override void initBinder(HttpServletRequest request, ServletRequestDataBinder binder); SearchCommand getDefaultCommand(); @SuppressWarnings("unchecked") ModelAndView prepareSearchView(HttpServletRequest request, 
			                              HttpServletResponse response,
			                              BindException errors); @SuppressWarnings("unchecked") ModelAndView prepareSearchView(HttpServletRequest request, 
			                              HttpServletResponse response,
			                              SearchCommand command,
			                              BindException errors); void setTargetManager(TargetManager targetManager); void setAgencyUserManager(AgencyUserManager agencyUserManager); void setMessageSource(MessageSource messageSource); void setDefaultSearchOnAgencyOnly(boolean defaultSearchOnAgencyOnly); boolean getDefaultSearchOnAgencyOnly(); void setGroupTypesList(WCTTreeSet groupTypesList); void setSubGroupType(String subGroupType); void setSubGroupSeparator(String subGroupSeparator);  }
@Test public final void testShowForm() { try { MockHttpServletRequest request = new MockHttpServletRequest(); MockHttpServletResponse response = new MockHttpServletResponse(); this.testSetAgencyUserManager(); this.testSetTargetManager(); this.testSetMessageSource(); this.testSetGroupTypesList(); BindException aError = new BindException(new SearchCommand(), null); testInstance.showForm(request, response, aError); } catch (Exception e) { String message = e.getClass().toString() + " - " + e.getMessage(); log.debug(message); fail(message); } }