Search in sources :

Example 11 with EventSourceEntity

use of org.mifos.platform.questionnaire.domain.EventSourceEntity in project head by mifos.

the class QuestionnaireServiceIntegrationTest method verifyEventSources.

private void verifyEventSources(QuestionGroup questionGroup) {
    Set<EventSourceEntity> eventSources = questionGroup.getEventSources();
    assertNotNull(eventSources);
    Assert.assertEquals(1, eventSources.size());
    EventSourceEntity eventSourceEntity = eventSources.toArray(new EventSourceEntity[eventSources.size()])[0];
    Assert.assertEquals("Create", eventSourceEntity.getEvent().getName());
    Assert.assertEquals("Client", eventSourceEntity.getSource().getEntityType());
    Assert.assertEquals("Create Client", eventSourceEntity.getDescription());
}
Also used : EventSourceEntity(org.mifos.platform.questionnaire.domain.EventSourceEntity)

Aggregations

EventSourceEntity (org.mifos.platform.questionnaire.domain.EventSourceEntity)11 EventSourceDto (org.mifos.platform.questionnaire.service.dtos.EventSourceDto)5 Test (org.junit.Test)4 QuestionGroup (org.mifos.platform.questionnaire.domain.QuestionGroup)4 Section (org.mifos.platform.questionnaire.domain.Section)4 QuestionGroupDetail (org.mifos.platform.questionnaire.service.QuestionGroupDetail)4 SectionDetail (org.mifos.platform.questionnaire.service.SectionDetail)4 EntityMaster (org.mifos.framework.business.EntityMaster)3 EventEntity (org.mifos.platform.questionnaire.domain.EventEntity)3 SectionQuestion (org.mifos.platform.questionnaire.domain.SectionQuestion)3 QuestionEntity (org.mifos.platform.questionnaire.domain.QuestionEntity)2 ArrayList (java.util.ArrayList)1 HashSet (java.util.HashSet)1 EventSourcesMatcher (org.mifos.platform.questionnaire.matchers.EventSourcesMatcher)1 SectionQuestionDetail (org.mifos.platform.questionnaire.service.SectionQuestionDetail)1