Search in sources :

Example 6 with CreateClientEnterMfiDataPage

use of org.mifos.test.acceptance.framework.client.CreateClientEnterMfiDataPage in project head by mifos.

the class ClientTestHelper method createClientMFIInformationAndGoToPreviewPage.

public CreateClientPreviewDataPage createClientMFIInformationAndGoToPreviewPage(String loanOfficer, CreateClientEnterMfiDataPage clientMfiDataPage) {
    CreateClientEnterMfiDataPage.SubmitFormParameters mfiFormParameters = new CreateClientEnterMfiDataPage.SubmitFormParameters();
    mfiFormParameters.setLoanOfficerId(loanOfficer);
    MeetingParameters meetingFormParameters = new MeetingParameters();
    meetingFormParameters.setWeekFrequency("1");
    meetingFormParameters.setWeekDay(MeetingParameters.WeekDay.WEDNESDAY);
    meetingFormParameters.setMeetingPlace("Mangalore");
    mfiFormParameters.setMeeting(meetingFormParameters);
    return clientMfiDataPage.submitAndGotoCreateClientPreviewDataPage(mfiFormParameters);
}
Also used : MeetingParameters(org.mifos.test.acceptance.framework.center.MeetingParameters) CreateClientEnterMfiDataPage(org.mifos.test.acceptance.framework.client.CreateClientEnterMfiDataPage)

Example 7 with CreateClientEnterMfiDataPage

use of org.mifos.test.acceptance.framework.client.CreateClientEnterMfiDataPage in project head by mifos.

the class ClientTest method createClientWithCorrectAgeTest.

@SuppressWarnings("PMD.SignatureDeclareThrowsException")
@Test(enabled = true)
public void createClientWithCorrectAgeTest() throws Exception {
    propertiesHelper.setMinimumAgeForClients(18);
    propertiesHelper.setMaximumAgeForClients(60);
    CreateClientEnterPersonalDataPage clientPersonalDataPage = clientTestHelper.createClient("MyOfficeDHMFT", "11", "12", "1987");
    CreateClientEnterMfiDataPage nextPage = clientPersonalDataPage.submitAndGotoCreateClientEnterMfiDataPage();
    nextPage.verifyPage("CreateClientMfiInfo");
    propertiesHelper.setMinimumAgeForClients(0);
    propertiesHelper.setMaximumAgeForClients(0);
}
Also used : CreateClientEnterPersonalDataPage(org.mifos.test.acceptance.framework.client.CreateClientEnterPersonalDataPage) CreateClientEnterMfiDataPage(org.mifos.test.acceptance.framework.client.CreateClientEnterMfiDataPage) Test(org.testng.annotations.Test)

Example 8 with CreateClientEnterMfiDataPage

use of org.mifos.test.acceptance.framework.client.CreateClientEnterMfiDataPage in project head by mifos.

the class ClientTestHelper method navigateToConfirmationPage.

private CreateClientConfirmationPage navigateToConfirmationPage(String loanOfficer) {
    CreateClientEnterMfiDataPage.SubmitFormParameters mfiFormParameters = new CreateClientEnterMfiDataPage.SubmitFormParameters();
    mfiFormParameters.setLoanOfficerId(loanOfficer);
    MeetingParameters meetingFormParameters = new MeetingParameters();
    meetingFormParameters.setWeekFrequency("1");
    meetingFormParameters.setWeekDay(MeetingParameters.WeekDay.WEDNESDAY);
    meetingFormParameters.setMeetingPlace("Bangalore");
    mfiFormParameters.setMeeting(meetingFormParameters);
    CreateClientPreviewDataPage clientPreviewDataPage = new CreateClientEnterMfiDataPage(selenium).submitAndGotoCreateClientPreviewDataPage(mfiFormParameters);
    CreateClientConfirmationPage clientConfirmationPage = clientPreviewDataPage.submit();
    clientConfirmationPage.verifyPage();
    return clientConfirmationPage;
}
Also used : MeetingParameters(org.mifos.test.acceptance.framework.center.MeetingParameters) CreateClientPreviewDataPage(org.mifos.test.acceptance.framework.client.CreateClientPreviewDataPage) CreateClientEnterMfiDataPage(org.mifos.test.acceptance.framework.client.CreateClientEnterMfiDataPage) CreateClientConfirmationPage(org.mifos.test.acceptance.framework.client.CreateClientConfirmationPage)

Example 9 with CreateClientEnterMfiDataPage

use of org.mifos.test.acceptance.framework.client.CreateClientEnterMfiDataPage in project head by mifos.

the class ClientTestHelper method createClientWithQuestionGroups.

public ClientViewDetailsPage createClientWithQuestionGroups(CreateClientEnterPersonalDataPage.SubmitFormParameters parameters, String group, QuestionResponseParameters responseParams) {
    QuestionResponsePage questionResponsePage = navigateToQuestionResponsePage(parameters, group);
    questionResponsePage.populateAnswers(responseParams);
    CreateClientEnterMfiDataPage createClientEnterMfiDataPage = questionResponsePage.navigateToNextPageClientCreation();
    CreateClientPreviewDataPage clientPreviewDataPage = createClientEnterMfiDataPage.navigateToPreview();
    clientPreviewDataPage.submit();
    return navigateToClientViewDetails(parameters);
}
Also used : CreateClientPreviewDataPage(org.mifos.test.acceptance.framework.client.CreateClientPreviewDataPage) QuestionResponsePage(org.mifos.test.acceptance.framework.questionnaire.QuestionResponsePage) CreateClientEnterMfiDataPage(org.mifos.test.acceptance.framework.client.CreateClientEnterMfiDataPage)

Example 10 with CreateClientEnterMfiDataPage

use of org.mifos.test.acceptance.framework.client.CreateClientEnterMfiDataPage in project head by mifos.

the class AddFamilyDetailsTest method canEditAfterSubmit.

@SuppressWarnings("PMD.SignatureDeclareThrowsException")
public void canEditAfterSubmit() throws Exception {
    propertiesHelper.setMaximumNumberOfFamilyMemebers(10);
    CreateClientEnterPersonalDataPage clientPersonalDataPage1 = clientTestHelper.createClientForFamilyInfo("MyOfficeDHMFT", "11", "12", "1988");
    CreateClientEnterFamilyDetailsPage clientFamilyDataPage = clientPersonalDataPage1.submitAndGotoCreateClientEnterFamilyDetailsPage();
    clientFamilyDataPage = clientTestHelper.createFamily("fname", "lname", "11", "01", "1987", clientFamilyDataPage);
    CreateClientEnterMfiDataPage nextPage = clientFamilyDataPage.submitAndGotoCreateClientEnterMfiDataPage();
    CreateClientPreviewDataPage clientPreviewDataPage1 = clientTestHelper.createClientMFIInformationAndGoToPreviewPage("loan officer", nextPage);
    clientPreviewDataPage1.submit();
    selenium.click("client_creationConfirmation.link.viewClientDetailsLink");
    selenium.waitForPageToLoad("30000");
    ClientViewDetailsPage clientDetailsPage = new ClientViewDetailsPage(selenium);
    ClientEditFamilyPage editFamilyPage = clientDetailsPage.editFamilyInformation();
    ClientEditFamilyParameters editParameters = new ClientEditFamilyParameters();
    editParameters.setFirstName("newName");
    editParameters.setRelationship(1);
    editParameters.setLastName("newLastName");
    editParameters.setDateOfBirthDD("11");
    editParameters.setDateOfBirthMM("12");
    editParameters.setDateOfBirthYY("2008");
    editParameters.setGender(49);
    editParameters.setLivingStatus(620);
    ClientFamilyEditPreviewPage previewEdit = editFamilyPage.submitAndNavigateToClientEditFamilyPreviewPage(editParameters);
    previewEdit.verifyPage();
    clientDetailsPage = previewEdit.submit();
    //Assert.assertTrue(selenium.isTextPresent("newName newLastName"));
    Assert.assertEquals(selenium.getText("displayName"), "newName newLastName");
}
Also used : CreateClientEnterPersonalDataPage(org.mifos.test.acceptance.framework.client.CreateClientEnterPersonalDataPage) CreateClientPreviewDataPage(org.mifos.test.acceptance.framework.client.CreateClientPreviewDataPage) ClientEditFamilyPage(org.mifos.test.acceptance.framework.client.ClientEditFamilyPage) CreateClientEnterFamilyDetailsPage(org.mifos.test.acceptance.framework.client.CreateClientEnterFamilyDetailsPage) ClientViewDetailsPage(org.mifos.test.acceptance.framework.client.ClientViewDetailsPage) ClientFamilyEditPreviewPage(org.mifos.test.acceptance.framework.client.ClientFamilyEditPreviewPage) CreateClientEnterMfiDataPage(org.mifos.test.acceptance.framework.client.CreateClientEnterMfiDataPage) ClientEditFamilyParameters(org.mifos.test.acceptance.framework.client.ClientEditFamilyParameters)

Aggregations

CreateClientEnterMfiDataPage (org.mifos.test.acceptance.framework.client.CreateClientEnterMfiDataPage)14 CreateClientEnterPersonalDataPage (org.mifos.test.acceptance.framework.client.CreateClientEnterPersonalDataPage)10 CreateClientPreviewDataPage (org.mifos.test.acceptance.framework.client.CreateClientPreviewDataPage)9 CreateClientEnterFamilyDetailsPage (org.mifos.test.acceptance.framework.client.CreateClientEnterFamilyDetailsPage)7 MeetingParameters (org.mifos.test.acceptance.framework.center.MeetingParameters)4 CreateClientConfirmationPage (org.mifos.test.acceptance.framework.client.CreateClientConfirmationPage)3 Test (org.testng.annotations.Test)3 ClientViewDetailsPage (org.mifos.test.acceptance.framework.client.ClientViewDetailsPage)2 SubmitFormParameters (org.mifos.test.acceptance.framework.admin.FeesCreatePage.SubmitFormParameters)1 CreateCenterEnterDataPage (org.mifos.test.acceptance.framework.center.CreateCenterEnterDataPage)1 CreateMeetingPage (org.mifos.test.acceptance.framework.center.CreateMeetingPage)1 ClientEditFamilyPage (org.mifos.test.acceptance.framework.client.ClientEditFamilyPage)1 ClientEditFamilyParameters (org.mifos.test.acceptance.framework.client.ClientEditFamilyParameters)1 ClientFamilyEditPreviewPage (org.mifos.test.acceptance.framework.client.ClientFamilyEditPreviewPage)1 CreateGroupSubmitParameters (org.mifos.test.acceptance.framework.group.CreateGroupEntryPage.CreateGroupSubmitParameters)1 SubmitFormParameters (org.mifos.test.acceptance.framework.loanproduct.DefineNewLoanProductPage.SubmitFormParameters)1 QuestionResponsePage (org.mifos.test.acceptance.framework.questionnaire.QuestionResponsePage)1 GroupTestHelper (org.mifos.test.acceptance.framework.testhelpers.GroupTestHelper)1