Search in sources :

Example 11 with CollectionSheetEntryEnterDataPage

use of org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryEnterDataPage in project head by mifos.

the class CollectionSheetEntryTest method navigateToCollectionSheetEntryEnterData.

private CollectionSheetEntryEnterDataPage navigateToCollectionSheetEntryEnterData(SubmitFormParameters formParameters) {
    CollectionSheetEntrySelectPage selectPage = new CollectionSheetEntryTestHelper(selenium).loginAndNavigateToCollectionSheetEntrySelectPage();
    selectPage.verifyPage();
    CollectionSheetEntryEnterDataPage enterDataPage = selectPage.submitAndGotoCollectionSheetEntryEnterDataPage(formParameters);
    enterDataPage.verifyPage();
    return enterDataPage;
}
Also used : CollectionSheetEntrySelectPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntrySelectPage) CollectionSheetEntryTestHelper(org.mifos.test.acceptance.framework.testhelpers.CollectionSheetEntryTestHelper) CollectionSheetEntryEnterDataPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryEnterDataPage)

Example 12 with CollectionSheetEntryEnterDataPage

use of org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryEnterDataPage in project head by mifos.

the class CollectionSheetEntryTest method defaultAdminUserSelectsValidCollectionSheetEntryParameters.

// one of the dependent methods throws Exception
@SuppressWarnings("PMD.SignatureDeclareThrowsException")
@Test(enabled = true)
public void defaultAdminUserSelectsValidCollectionSheetEntryParameters() throws Exception {
    SubmitFormParameters formParameters = new SubmitFormParameters();
    formParameters.setBranch("Office1");
    formParameters.setLoanOfficer("Bagonza Wilson");
    formParameters.setCenter("Center1");
    formParameters.setPaymentMode("Cash");
    initRemote.dataLoadAndCacheRefresh(dbUnitUtilities, "acceptance_small_001_dbunit.xml", dataSource, selenium);
    CollectionSheetEntrySelectPage selectPage = new CollectionSheetEntryTestHelper(selenium).loginAndNavigateToCollectionSheetEntrySelectPage();
    selectPage.verifyPage();
    CollectionSheetEntryEnterDataPage enterDataPage = selectPage.submitAndGotoCollectionSheetEntryEnterDataPage(formParameters);
    enterDataPage.enterAccountValue(0, 0, 99.0);
    enterDataPage.enterAccountValue(1, 1, 0.0);
    enterDataPage.enterAccountValue(2, 0, 0.0);
    CollectionSheetEntryPreviewDataPage previewPage = enterDataPage.submitAndGotoCollectionSheetEntryPreviewDataPage();
    previewPage.verifyPage(formParameters);
    CollectionSheetEntryConfirmationPage confirmationPage = previewPage.submitAndGotoCollectionSheetEntryConfirmationPage();
    confirmationPage.verifyPage();
    verifyCollectionSheetData("acceptance_small_002_dbunit.xml");
}
Also used : CollectionSheetEntryPreviewDataPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryPreviewDataPage) CollectionSheetEntrySelectPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntrySelectPage) CollectionSheetEntryTestHelper(org.mifos.test.acceptance.framework.testhelpers.CollectionSheetEntryTestHelper) CollectionSheetEntryConfirmationPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryConfirmationPage) SubmitFormParameters(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntrySelectPage.SubmitFormParameters) CollectionSheetEntryEnterDataPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryEnterDataPage) Test(org.testng.annotations.Test)

Example 13 with CollectionSheetEntryEnterDataPage

use of org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryEnterDataPage in project head by mifos.

the class CollectionSheetEntryCustomerAccountTest method enterAndSubmitCustomerAccountData.

private CollectionSheetEntryConfirmationPage enterAndSubmitCustomerAccountData(SubmitFormParameters formParameters, double[] customerAcctValues) {
    CollectionSheetEntrySelectPage selectPage = new CollectionSheetEntryTestHelper(selenium).loginAndNavigateToCollectionSheetEntrySelectPage();
    selectPage.verifyPage();
    CollectionSheetEntryEnterDataPage enterDataPage = selectCenterAndContinue(formParameters, selectPage);
    enterFirstGroupCustomerAccountValues(enterDataPage, customerAcctValues);
    enterGenericCustomerAccountValues(enterDataPage);
    CollectionSheetEntryPreviewDataPage previewPage = enterDataPage.submitAndGotoCollectionSheetEntryPreviewDataPage();
    previewPage.verifyPage(formParameters);
    CollectionSheetEntryConfirmationPage confirmationPage = previewPage.submitAndGotoCollectionSheetEntryConfirmationPage();
    confirmationPage.verifyPage();
    return confirmationPage;
}
Also used : CollectionSheetEntryPreviewDataPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryPreviewDataPage) CollectionSheetEntrySelectPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntrySelectPage) CollectionSheetEntryTestHelper(org.mifos.test.acceptance.framework.testhelpers.CollectionSheetEntryTestHelper) CollectionSheetEntryConfirmationPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryConfirmationPage) CollectionSheetEntryEnterDataPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryEnterDataPage)

Example 14 with CollectionSheetEntryEnterDataPage

use of org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryEnterDataPage in project head by mifos.

the class CollectionSheetEntryCustomerAccountTest method previousPaidFeeNotDisplayedOnSecondCollectionSheetEntry.

@SuppressWarnings("PMD.SignatureDeclareThrowsException")
public // one of the dependent methods throws Exception
void previousPaidFeeNotDisplayedOnSecondCollectionSheetEntry() throws Exception {
    SubmitFormParameters formParameters = getFormParametersForTestOffice();
    initRemote.dataLoadAndCacheRefresh(dbUnitUtilities, "acceptance_small_003_dbunit.xml", dataSource, selenium);
    CollectionSheetEntryConfirmationPage confirmationPage = enterAndSubmitCustomerAccountData(formParameters, BASIC_CUSTOMER_ACCT_VALUES);
    // navigate back to collection sheet entry
    HomePage homePage = confirmationPage.navigateToHomePage();
    ClientsAndAccountsHomepage clientsAndAccountsPage = homePage.navigateToClientsAndAccountsUsingHeaderTab();
    CollectionSheetEntrySelectPage selectPage = clientsAndAccountsPage.navigateToEnterCollectionSheetDataUsingLeftMenu();
    selectPage.verifyPage();
    // enter same search data and inspect displayed client account (A/C
    // Collection) values
    CollectionSheetEntryEnterDataPage enterDataPage = selectCenterAndContinue(formParameters, selectPage);
    enterDataPage.verifyCustomerAccountValue(0, 6, 0.0);
    enterDataPage.verifyCustomerAccountValue(1, 6, 0.0);
    enterDataPage.verifyCustomerAccountValue(2, 6, 0.0);
    enterDataPage.verifyCustomerAccountValue(3, 6, 0.0);
    enterDataPage.verifyCustomerAccountValue(4, 6, 0.0);
    enterDataPage.cancel();
}
Also used : HomePage(org.mifos.test.acceptance.framework.HomePage) CollectionSheetEntrySelectPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntrySelectPage) CollectionSheetEntryConfirmationPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryConfirmationPage) ClientsAndAccountsHomepage(org.mifos.test.acceptance.framework.ClientsAndAccountsHomepage) SubmitFormParameters(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntrySelectPage.SubmitFormParameters) CollectionSheetEntryEnterDataPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryEnterDataPage)

Example 15 with CollectionSheetEntryEnterDataPage

use of org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryEnterDataPage in project head by mifos.

the class CollectionSheetEntryInputErrorsTest method enteringAnInvalidAmountAndClickingPreviewShouldCauseAReturnToCollectionSheetEntryPage.

@SuppressWarnings("PMD.SignatureDeclareThrowsException")
public // one of the dependent methods throws Exception
void enteringAnInvalidAmountAndClickingPreviewShouldCauseAReturnToCollectionSheetEntryPage() throws Exception {
    initRemote.dataLoadAndCacheRefresh(dbUnitUtilities, "acceptance_small_003_dbunit.xml", dataSource, selenium);
    SubmitFormParameters formParameters = getFormParametersForTestOffice();
    CollectionSheetEntryEnterDataPage enterDataPage = navigateToCollectionSheetEntryPage(formParameters);
    enterDataPage.verifyPage();
    // invalid amount
    enterDataPage.enterCustomerAccountValue(0, 6, -5);
    CollectionSheetEntryEnterDataPage nextPage = enterDataPage.clickPreviewButton();
    nextPage.verifyPage();
}
Also used : SubmitFormParameters(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntrySelectPage.SubmitFormParameters) CollectionSheetEntryEnterDataPage(org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryEnterDataPage)

Aggregations

CollectionSheetEntryEnterDataPage (org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryEnterDataPage)15 CollectionSheetEntrySelectPage (org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntrySelectPage)9 SubmitFormParameters (org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntrySelectPage.SubmitFormParameters)8 CollectionSheetEntryConfirmationPage (org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryConfirmationPage)7 CollectionSheetEntryTestHelper (org.mifos.test.acceptance.framework.testhelpers.CollectionSheetEntryTestHelper)7 CollectionSheetEntryPreviewDataPage (org.mifos.test.acceptance.framework.collectionsheet.CollectionSheetEntryPreviewDataPage)6 Test (org.testng.annotations.Test)4 ClientsAndAccountsHomepage (org.mifos.test.acceptance.framework.ClientsAndAccountsHomepage)2 HomePage (org.mifos.test.acceptance.framework.HomePage)2