HttpServletRequest request = mock(HttpServletRequest.class);
HttpServlet servlet = mock(HttpServlet.class);
when(this.servletConfig.getServletContext()).thenReturn(
this.servletContext);
SuggestTree generalIndex = new SuggestTree(7);
generalIndex.put("Metallica", 100, "Metallica");
generalIndex.put("Megadeth", 99, "Metallica");
generalIndex.put("Megaherz", 98, "Metallica");
generalIndex.put("Meshuggah", 97, "Metallica");
generalIndex.put("Menhir", 96, "Metallica");
generalIndex.put("Meat Loaf", 95, "Metallica");
generalIndex.put("Melechesh", 94, "Metallica");
when(
this.servletContext.getAttribute("indexName:"
+ ProtocolConstants.DEFAULT_INDEX_NAME)).thenReturn(
generalIndex);
SuggestTree venueIndex = new SuggestTree(7);
venueIndex.put("Das Kult", 55, "http://www.daskult.de");
venueIndex.put("Die Halle", 44, "http://www.diehalle-frankfurt.de");
venueIndex.put("Die Mühle", 30, "http://www.die-muehle.net");
venueIndex.put("Dreams", 30, "http://www.discothek-dreams.de");
venueIndex.put("Dudelsack", 27, "http://www.dudelsack-bk.de");
venueIndex.put("Das Haus", 25, "http://www.dashaus-lu.de/home.html");
venueIndex.put("Druckluftkammer", 25, "http://www.druckluftkammer.de/");
when(this.servletContext.getAttribute("indexName:" + "venueIndex"))
.thenReturn(venueIndex);
HashMap<String, String> imageIndex = new HashMap<String, String>();