Search in sources :

Example 1 with ClientsAndAccountsHomepage

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

the class LoanTestHelper method navigateToCreateLoanAccountEntryPageWithoutLogout.

public CreateLoanAccountEntryPage navigateToCreateLoanAccountEntryPageWithoutLogout(CreateLoanAccountSearchParameters searchParameters) {
    ClientsAndAccountsHomepage clientsAndAccountsPage = new HomePage(selenium).navigateToClientsAndAccountsUsingHeaderTab();
    CreateLoanAccountSearchPage createLoanAccountSearchPage = clientsAndAccountsPage.navigateToCreateLoanAccountUsingLeftMenu();
    createLoanAccountSearchPage.verifyPage();
    CreateLoanAccountEntryPage createLoanAccountEntryPage = createLoanAccountSearchPage.searchAndNavigateToCreateLoanAccountPage(searchParameters);
    createLoanAccountEntryPage.verifyPage();
    return createLoanAccountEntryPage;
}
Also used : HomePage(org.mifos.test.acceptance.framework.HomePage) CreateLoanAccountSearchPage(org.mifos.test.acceptance.framework.loan.CreateLoanAccountSearchPage) ClientsAndAccountsHomepage(org.mifos.test.acceptance.framework.ClientsAndAccountsHomepage) CreateLoanAccountEntryPage(org.mifos.test.acceptance.framework.loan.CreateLoanAccountEntryPage)

Example 2 with ClientsAndAccountsHomepage

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

the class ClientTestHelper method navigateToPersonalDataPage.

private CreateClientEnterPersonalDataPage navigateToPersonalDataPage(String officeName) {
    ClientsAndAccountsHomepage clientsAndAccountsPage = navigationHelper.navigateToClientsAndAccountsPage();
    GroupSearchPage groupSearchPage = clientsAndAccountsPage.navigateToCreateNewClientPage();
    ChooseOfficePage chooseOfficePage = groupSearchPage.navigateToCreateClientWithoutGroupPage();
    return chooseOfficePage.chooseOffice(officeName);
}
Also used : GroupSearchPage(org.mifos.test.acceptance.framework.group.GroupSearchPage) ClientsAndAccountsHomepage(org.mifos.test.acceptance.framework.ClientsAndAccountsHomepage) ChooseOfficePage(org.mifos.test.acceptance.framework.client.ChooseOfficePage)

Example 3 with ClientsAndAccountsHomepage

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

the class CreateGroupLoanAccountTest method newMonthlyGroupLoanAccountWithMeetingOnSpecificDayOfMonth.

@Test(enabled = true)
@SuppressWarnings({ "PMD.SignatureDeclareThrowsException" })
public void newMonthlyGroupLoanAccountWithMeetingOnSpecificDayOfMonth() throws Exception {
    //Given
    DateTimeUpdaterRemoteTestingService dateTimeUpdaterRemoteTestingService = new DateTimeUpdaterRemoteTestingService(selenium);
    DateTime targetTime = new DateTime(2010, 8, 13, 1, 0, 0, 0);
    dateTimeUpdaterRemoteTestingService.setDateTime(targetTime);
    //When
    homePage = loginSuccessfully();
    CreateLoanAccountSearchParameters searchParameters = new CreateLoanAccountSearchParameters();
    searchParameters.setSearchString("MonthlyGroup");
    searchParameters.setLoanProduct("MonthlyGroupFlatLoan1stOfMonth");
    CreateLoanAccountSubmitParameters submitAccountParameters = new CreateLoanAccountSubmitParameters();
    submitAccountParameters.setAmount("1000.0");
    ClientsAndAccountsHomepage clientsAndAccountsPage = homePage.navigateToClientsAndAccountsUsingHeaderTab();
    CreateLoanAccountSearchPage createLoanAccountSearchPage = clientsAndAccountsPage.navigateToCreateLoanAccountUsingLeftMenu();
    CreateLoanAccountEntryPage createLoanAccountEntryPage = createLoanAccountSearchPage.searchAndNavigateToCreateLoanAccountPage(searchParameters);
    createLoanAccountEntryPage.verifyPage();
    CreateLoanAccountConfirmationPage createLoanAccountConfirmationPage = createLoanAccountEntryPage.submitAndNavigateToLoanAccountConfirmationPage(submitAccountParameters);
    createLoanAccountConfirmationPage.navigateToLoanAccountDetailsPage();
}
Also used : CreateLoanAccountSearchParameters(org.mifos.test.acceptance.framework.loan.CreateLoanAccountSearchParameters) CreateLoanAccountSearchPage(org.mifos.test.acceptance.framework.loan.CreateLoanAccountSearchPage) CreateLoanAccountSubmitParameters(org.mifos.test.acceptance.framework.loan.CreateLoanAccountSubmitParameters) ClientsAndAccountsHomepage(org.mifos.test.acceptance.framework.ClientsAndAccountsHomepage) CreateLoanAccountConfirmationPage(org.mifos.test.acceptance.framework.loan.CreateLoanAccountConfirmationPage) DateTimeUpdaterRemoteTestingService(org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService) DateTime(org.joda.time.DateTime) CreateLoanAccountEntryPage(org.mifos.test.acceptance.framework.loan.CreateLoanAccountEntryPage) Test(org.testng.annotations.Test)

Example 4 with ClientsAndAccountsHomepage

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

the class CreateGroupLoanAccountTest method newWeeklyGroupLoanAccount.

//http://mifosforge.jira.com/browse/MIFOSTEST-303
@SuppressWarnings("PMD.SignatureDeclareThrowsException")
public void newWeeklyGroupLoanAccount() throws Exception {
    //Given
    DateTimeUpdaterRemoteTestingService dateTimeUpdaterRemoteTestingService = new DateTimeUpdaterRemoteTestingService(selenium);
    DateTime targetTime = new DateTime(2011, 2, 25, 1, 0, 0, 0);
    dateTimeUpdaterRemoteTestingService.setDateTime(targetTime);
    //When
    ClientsAndAccountsHomepage clientsAndAccountsHomepage = navigationHelper.navigateToClientsAndAccountsPage();
    CreateLoanAccountSearchPage createLoanAccountSearchPage = clientsAndAccountsHomepage.navigateToCreateLoanAccountUsingLeftMenu();
    CreateLoanAccountSearchParameters formParameters = new CreateLoanAccountSearchParameters();
    formParameters.setSearchString("groupWithoutLoan");
    formParameters.setLoanProduct("WeeklyGroupFlatLoanWithOnetimeFee");
    CreateLoanAccountEntryPage createLoanAccountEntryPage = createLoanAccountSearchPage.searchAndNavigateToCreateLoanAccountPage(formParameters);
    createLoanAccountEntryPage.setAmount("3000.0");
    createLoanAccountEntryPage.setDisbursalDate(new DateTime(2011, 2, 25, 15, 0, 0, 0));
    selectAdditionalFees();
    CreateLoanAccountReviewInstallmentPage createLoanAccountReviewInstallmentPage = createLoanAccountEntryPage.navigateToReviewInstallmentsPage();
    verifyFirstInstallmentDateAndDisbursalDateOnReviewPage();
    verifyAdditionalFeesOnReviewPage();
    CreateLoanAccountPreviewPage createLoanAccountPreviewPage = createLoanAccountReviewInstallmentPage.clickPreviewAndGoToReviewLoanAccountPage();
    verifyFirstInstallmentDateAndDisbursalDateOnPreviewPage();
    CreateLoanAccountConfirmationPage createLoanAccountConfirmationPage = createLoanAccountPreviewPage.submitForApprovalAndNavigateToConfirmationPage();
    LoanAccountPage loanAccountPage = createLoanAccountConfirmationPage.navigateToLoanAccountDetailsPage();
    String loanId = loanAccountPage.getAccountId();
    loanAccountPage.verifyLoanIsPendingApproval();
    loanAccountPage.verifyNumberOfInstallments("4");
    loanAccountPage.verifyDisbursalDate("25/02/2011");
    loanAccountPage.verifyPrincipalOriginal("3,000");
    loanAccountPage.verifyLoanTotalBalance("3,466");
    loanAccountPage.verifyFeesOriginal("410");
    loanAccountPage.verifyInterestOriginal("56");
    verifyFees();
    ViewRepaymentSchedulePage viewRepaymentSchedulePage = loanAccountPage.navigateToViewRepaymentSchedule();
    viewRepaymentSchedulePage.verifyRepaymentScheduleTableDueDate(3, "04-Mar-2011");
    viewRepaymentSchedulePage.verifyRepaymentScheduleTableDueDate(4, "11-Mar-2011");
    viewRepaymentSchedulePage.verifyRepaymentScheduleTableDueDate(5, "18-Mar-2011");
    viewRepaymentSchedulePage.verifyRepaymentScheduleTableDueDate(6, "25-Mar-2011");
    viewRepaymentSchedulePage.verifyRepaymentScheduleTablePrincipal(3, "750.2");
    viewRepaymentSchedulePage.verifyRepaymentScheduleTablePrincipal(4, "750.2");
    viewRepaymentSchedulePage.verifyRepaymentScheduleTablePrincipal(5, "750.2");
    viewRepaymentSchedulePage.verifyRepaymentScheduleTablePrincipal(6, "749.4");
    viewRepaymentSchedulePage.verifyRepaymentScheduleTableFees(3, "110");
    viewRepaymentSchedulePage.verifyRepaymentScheduleTableFees(4, "100");
    viewRepaymentSchedulePage.verifyRepaymentScheduleTableFees(5, "100");
    viewRepaymentSchedulePage.verifyRepaymentScheduleTableFees(6, "100");
    viewRepaymentSchedulePage.navigateToLoanAccountPage();
    EditLoanAccountStatusParameters editLoanAccountStatusParameters = new EditLoanAccountStatusParameters();
    editLoanAccountStatusParameters.setStatus(EditLoanAccountStatusParameters.APPROVED);
    editLoanAccountStatusParameters.setNote("test");
    loanTestHelper.changeLoanAccountStatus(loanId, editLoanAccountStatusParameters);
    DisburseLoanParameters disburseParameters = new DisburseLoanParameters();
    disburseParameters.setPaymentType(DisburseLoanParameters.CASH);
    disburseParameters.setDisbursalDateDD("25");
    disburseParameters.setDisbursalDateMM("02");
    disburseParameters.setDisbursalDateYYYY("2011");
    loanTestHelper.disburseLoan(loanId, disburseParameters);
}
Also used : EditLoanAccountStatusParameters(org.mifos.test.acceptance.framework.loan.EditLoanAccountStatusParameters) DisburseLoanParameters(org.mifos.test.acceptance.framework.loan.DisburseLoanParameters) CreateLoanAccountSearchParameters(org.mifos.test.acceptance.framework.loan.CreateLoanAccountSearchParameters) ViewRepaymentSchedulePage(org.mifos.test.acceptance.framework.loan.ViewRepaymentSchedulePage) CreateLoanAccountSearchPage(org.mifos.test.acceptance.framework.loan.CreateLoanAccountSearchPage) DateTime(org.joda.time.DateTime) CreateLoanAccountPreviewPage(org.mifos.test.acceptance.framework.loan.CreateLoanAccountPreviewPage) ClientsAndAccountsHomepage(org.mifos.test.acceptance.framework.ClientsAndAccountsHomepage) CreateLoanAccountConfirmationPage(org.mifos.test.acceptance.framework.loan.CreateLoanAccountConfirmationPage) LoanAccountPage(org.mifos.test.acceptance.framework.loan.LoanAccountPage) DateTimeUpdaterRemoteTestingService(org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService) CreateLoanAccountReviewInstallmentPage(org.mifos.test.acceptance.framework.loan.CreateLoanAccountReviewInstallmentPage) CreateLoanAccountEntryPage(org.mifos.test.acceptance.framework.loan.CreateLoanAccountEntryPage)

Example 5 with ClientsAndAccountsHomepage

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

the class SavingsAccountHelper method navigateToCreateSavingsAccountSearchPage.

private CreateSavingsAccountSearchPage navigateToCreateSavingsAccountSearchPage() {
    LoginPage loginPage = new AppLauncher(selenium).launchMifos().logout();
    loginPage.verifyPage();
    HomePage homePage = loginPage.loginSuccessfullyUsingDefaultCredentials();
    homePage.verifyPage();
    ClientsAndAccountsHomepage clientsAndAccountsPage = homePage.navigateToClientsAndAccountsUsingHeaderTab();
    return clientsAndAccountsPage.navigateToCreateSavingsAccountUsingLeftMenu();
}
Also used : HomePage(org.mifos.test.acceptance.framework.HomePage) ClientsAndAccountsHomepage(org.mifos.test.acceptance.framework.ClientsAndAccountsHomepage) AppLauncher(org.mifos.test.acceptance.framework.AppLauncher) LoginPage(org.mifos.test.acceptance.framework.login.LoginPage)

Aggregations

ClientsAndAccountsHomepage (org.mifos.test.acceptance.framework.ClientsAndAccountsHomepage)26 CreateLoanAccountSearchPage (org.mifos.test.acceptance.framework.loan.CreateLoanAccountSearchPage)12 CreateLoanAccountSearchParameters (org.mifos.test.acceptance.framework.loan.CreateLoanAccountSearchParameters)11 CreateLoanAccountEntryPage (org.mifos.test.acceptance.framework.loan.CreateLoanAccountEntryPage)10 Test (org.testng.annotations.Test)10 CreateLoanAccountConfirmationPage (org.mifos.test.acceptance.framework.loan.CreateLoanAccountConfirmationPage)8 DateTime (org.joda.time.DateTime)7 CreateLoanAccountPreviewPage (org.mifos.test.acceptance.framework.loan.CreateLoanAccountPreviewPage)7 CreateLoanAccountReviewInstallmentPage (org.mifos.test.acceptance.framework.loan.CreateLoanAccountReviewInstallmentPage)7 HomePage (org.mifos.test.acceptance.framework.HomePage)6 LoanAccountPage (org.mifos.test.acceptance.framework.loan.LoanAccountPage)4 ViewRepaymentSchedulePage (org.mifos.test.acceptance.framework.loan.ViewRepaymentSchedulePage)4 AdminPage (org.mifos.test.acceptance.framework.admin.AdminPage)3 CreateClientEnterPersonalDataPage (org.mifos.test.acceptance.framework.client.CreateClientEnterPersonalDataPage)3 CreateLoanAccountSubmitParameters (org.mifos.test.acceptance.framework.loan.CreateLoanAccountSubmitParameters)3 LoginPage (org.mifos.test.acceptance.framework.login.LoginPage)3 AppLauncher (org.mifos.test.acceptance.framework.AppLauncher)2 DefineHiddenMandatoryFieldsPage (org.mifos.test.acceptance.framework.admin.DefineHiddenMandatoryFieldsPage)2 ClientSearchResultsPage (org.mifos.test.acceptance.framework.client.ClientSearchResultsPage)2 ClientViewDetailsPage (org.mifos.test.acceptance.framework.client.ClientViewDetailsPage)2