TracingTemplateForm implements RecordForm { @Override public String toString() { StringBuilder sb = new StringBuilder("<Enquiries>").append("\n"); for (Section section : sections) { sb.append(section).append("\n"); } return sb.toString(); }  List<Section> getSections(); void setSections(List<Section> sections); @Override String toString();  }
@Test public void should_return_string_of_tracing_template_form_when_section_is_empty() throws Exception { TracingTemplateForm tracingTemplateForm = createTracingTemplateForm(); assertThat(tracingTemplateForm.toString(), is("<Enquiries>\n")); }