@Test
public void testAddSectionWithoutQuestions() throws Exception {

    when(requestContext.getMessageContext()).thenReturn(messageContext);
    QuestionGroupForm questionGroup = new QuestionGroupForm();
    questionGroup.setTitle("title");
    questionGroup.setSectionName("sectionName");
    String result = questionGroupController.addSection(questionGroup, requestContext);
    verify(requestContext).getMessageContext();
    verify(messageContext).addMessage(argThat(new MessageMatcher("questionnaire.error.no.question.in.section")));
    assertThat(result, Is.is("failure"));
}