use of org.mifos.test.acceptance.framework.questionnaire.QuestionGroupDetailPage in project head by mifos.
the class QuestionGroupTestHelper method naviagateToEditQuestionGroup.
public EditQuestionGroupPage naviagateToEditQuestionGroup(String questionGroup) {
AdminPage adminPage = navigationHelper.navigateToAdminPage();
ViewAllQuestionGroupsPage allQuestionGroupsPage = adminPage.navigateToViewAllQuestionGroups();
QuestionGroupDetailPage questionGroupDetailPage = allQuestionGroupsPage.navigateToQuestionGroupDetailPage(questionGroup);
return questionGroupDetailPage.navigateToEditPage();
}
use of org.mifos.test.acceptance.framework.questionnaire.QuestionGroupDetailPage in project head by mifos.
the class QuestionGroupTest method testQuestionGroupDetail.
private void testQuestionGroupDetail(ViewAllQuestionGroupsPage viewAllQuestionGroupsPage, String title, String sectionName, List<String> questions, List<String> mandatoryQuestions) {
QuestionGroupDetailPage questionGroupDetailPage = navigateToQuestionGroupDetailPage(viewAllQuestionGroupsPage, title);
testQuestionGroupDetail(questionGroupDetailPage, title, sectionName, questions, mandatoryQuestions);
questionGroupDetailPage.navigateToViewQuestionGroupsPage().verifyPage();
}
use of org.mifos.test.acceptance.framework.questionnaire.QuestionGroupDetailPage in project head by mifos.
the class QuestionGroupTest method editQuestionGroupsForCreateOffice.
/**
* Verify that user is able to edit the defined Question Groups
* and create Office with edited Question Group
* http://mifosforge.jira.com/browse/MIFOSTEST-666
*
* @throws Exception
*/
@Test(enabled = true)
@SuppressWarnings("PMD.SignatureDeclareThrowsException")
public void editQuestionGroupsForCreateOffice() throws Exception {
//When
ViewAllQuestionGroupsPage viewAllQuestionGroupsPage = questionGroupTestHelper.navigateToViewQuestionGroups(QUESTIONS_LIST);
String oldTitle = "CreateOffice";
EditQuestionGroupPage editQuestionGroupPage = viewAllQuestionGroupsPage.navigateToQuestionGroupDetailPage(oldTitle).navigateToEditPage();
editQuestionGroupPage.moveSectionUp("Misc");
editQuestionGroupPage.moveQuestionUp(9);
editQuestionGroupPage.moveQuestionDown(2);
String newTitle = "CreateOfficeQG";
QuestionGroupDetailPage questionGroupDetailPage = editQuestionGroupPage.editQuestionGroup(false, newTitle, "Create Office", Collections.<String>emptyList());
//Then
questionGroupDetailPage.verifyOrderQuestions(asList("MultiSelect", "Date", "FreeText"), 4);
questionGroupDetailPage.verifyOrderSections(asList("Misc", "Default"));
questionGroupDetailPage.verifyMandatoryQuestions(Arrays.asList("FreeText"), "Misc");
questionGroupDetailPage.verifyMandatoryQuestions(EMPTY_LIST, "Default");
questionGroupDetailPage.verifyTitle(newTitle);
questionGroupTestHelper.markQuestionGroupAsActive(newTitle);
createOfficeWithQuestionGroup();
questionGroupTestHelper.markQuestionGroupAsInactive(newTitle);
//When
viewAllQuestionGroupsPage = questionGroupDetailPage.navigateToViewQuestionGroupsPage();
//Then
viewAllQuestionGroupsPage.verifyInactiveQuestions(0, 0);
}
use of org.mifos.test.acceptance.framework.questionnaire.QuestionGroupDetailPage in project head by mifos.
the class QuestionGroupTest method navigateToQuestionGroupDetailPage.
private QuestionGroupDetailPage navigateToQuestionGroupDetailPage(ViewAllQuestionGroupsPage viewAllQuestionGroupsPage, String title) {
QuestionGroupDetailPage questionGroupDetailPage = viewAllQuestionGroupsPage.navigateToQuestionGroupDetailPage(title);
questionGroupDetailPage.verifyPage();
return questionGroupDetailPage;
}
use of org.mifos.test.acceptance.framework.questionnaire.QuestionGroupDetailPage in project head by mifos.
the class QuestionGroupTestHelper method naviagateToEditQuestionGroup.
public EditQuestionGroupPage naviagateToEditQuestionGroup(int questionGroupId) {
AdminPage adminPage = navigationHelper.navigateToAdminPage();
ViewAllQuestionGroupsPage allQuestionGroupsPage = adminPage.navigateToViewAllQuestionGroups();
QuestionGroupDetailPage questionGroupDetailPage = allQuestionGroupsPage.navigateToQuestionGroupDetailPage(questionGroupId);
return questionGroupDetailPage.navigateToEditPage();
}
Aggregations