### Question:
SingleTagParser extends AbstractIndexedParser<String> { @Override public String parse(final int startingIndex, final List<String> lines) { final EtmPoint point = PointFactory.getPoint(getClass(), "parse(int, List)"); try { final DocumentationTagIndexedSmoosher smoosher = new DocumentationTagIndexedSmoosher(); final String smooshed = smoosher.smoosh(startingIndex, lines); setEndingIndex(smoosher.getEndingIndex()); final int spacePos = smooshed.indexOf(' '); if (spacePos < 0) { return ""; } return smooshed.substring(spacePos + 1); } finally { point.collect(); } } SingleTagParser(final String tag); @Override boolean canParse(final String line); @Override String parse(final int startingIndex, final List<String> lines);  }### Answer:
@Test public void testParse() throws Exception { final int startingIndex = 23; final int endingIndex = 72; @SuppressWarnings("unchecked") final List<String> lines = mock(List.class); final String smooshed = tag + " smooshed"; final DocumentationTagIndexedSmoosher smoosher = mock(DocumentationTagIndexedSmoosher.class); whenNew(DocumentationTagIndexedSmoosher.class).withNoArguments().thenReturn(smoosher); when(smoosher.getEndingIndex()).thenReturn(endingIndex); when(smoosher.smoosh(startingIndex, lines)).thenReturn(smooshed); assertThat(parser.parse(startingIndex, lines)).isEqualTo("smooshed"); assertThat(parser.getEndingIndex()).isEqualTo(endingIndex); }
@Test public void testParseNoSpace() throws Exception { final int startingIndex = 23; @SuppressWarnings("unchecked") final List<String> lines = mock(List.class); final DocumentationTagIndexedSmoosher smoosher = mock(DocumentationTagIndexedSmoosher.class); whenNew(DocumentationTagIndexedSmoosher.class).withNoArguments().thenReturn(smoosher); when(smoosher.smoosh(startingIndex, lines)).thenReturn("noSpacesAtAll"); assertThat(parser.parse(startingIndex, lines)).isEmpty(); }