### Question:
SingleSectionSegmenter { public static final Section createSingleSection (String text, String sectionKind, UUID sectionUuid) { TextSpan ts = new TextSpan(0, text.length()); Section s = new Section(); s.setUuid(sectionUuid); s.setKind(sectionKind); s.setTextSpan(ts); return s; } private  SingleSectionSegmenter(); static final Section createSingleSection(String text, String sectionKind, UUID sectionUuid); static final Section createSingleSection(Communication c, String sectionKind); static void main(String... args);  }### Answer:
@Test public void validComm() throws ConcreteException { assertFalse(c.isSetSectionList()); Section s = SingleSectionSegmenter.createSingleSection(this.c, "passage"); c.addToSectionList(s); assertTrue(c.isSetSectionList()); assertEquals(1, c.getSectionListSize()); Section rs = c.getSectionList().get(0); assertEquals("passage", rs.getKind()); TextSpan ts = rs.getTextSpan(); assertEquals(0, ts.getStart()); assertEquals(c.getText().length(), ts.getEnding()); }
@Test(expected=ConcreteException.class) public void noText() throws ConcreteException { Communication ws = new Communication(this.c); ws.unsetText(); SingleSectionSegmenter.createSingleSection(ws, "passage"); }
@Test(expected=ConcreteException.class) public void emptyText() throws ConcreteException { Communication ws = new Communication(this.c); ws.setText(""); SingleSectionSegmenter.createSingleSection(ws, "passage"); }