Search in sources :

Example 36 with NavigationHelper

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

the class CenterMeetingTest method prepareGroupForTest.

private void prepareGroupForTest() {
    GroupTestHelper groupHelper = new GroupTestHelper(selenium);
    CreateGroupEntryPage.CreateGroupSubmitParameters groupParams = new CreateGroupEntryPage.CreateGroupSubmitParameters();
    groupName = StringUtil.getRandomString(8);
    groupParams.setGroupName(groupName);
    groupParams.setRecruitedBy(firstName + " " + lastName);
    groupHelper.createNewGroup(centerName, groupParams);
    groupHelper.activateGroup(groupName);
    new NavigationHelper(selenium).navigateToHomePage();
}
Also used : GroupTestHelper(org.mifos.test.acceptance.framework.testhelpers.GroupTestHelper) NavigationHelper(org.mifos.test.acceptance.framework.testhelpers.NavigationHelper) CreateGroupEntryPage(org.mifos.test.acceptance.framework.group.CreateGroupEntryPage)

Example 37 with NavigationHelper

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

the class CenterTest method verifyAcceptedPaymentTypesForCenter.

@SuppressWarnings("PMD.SignatureDeclareThrowsException")
// http://mifosforge.jira.com/browse/MIFOSTEST-246
@Test(enabled = true)
public void verifyAcceptedPaymentTypesForCenter() throws Exception {
    // When
    CreateCenterEnterDataPage.SubmitFormParameters formParameters = new CreateCenterEnterDataPage.SubmitFormParameters();
    String testCenterName = "Center" + StringUtil.getRandomString(6);
    formParameters.setCenterName(testCenterName);
    formParameters.setLoanOfficer("loan officer");
    MeetingParameters meeting = new MeetingParameters();
    meeting.setMeetingPlace("centerTestMeetingPlace" + StringUtil.getRandomString(2));
    meeting.setWeekFrequency("1");
    meeting.setWeekDay(MeetingParameters.WeekDay.MONDAY);
    formParameters.setMeeting(meeting);
    centerTestHelper.createCenter(formParameters, "MyOfficeDHMFT");
    NavigationHelper navigationHelper = new NavigationHelper(selenium);
    AdminPage adminPage = navigationHelper.navigateToAdminPage();
    DefineAcceptedPaymentTypesPage defineAcceptedPaymentTypesPage = adminPage.navigateToDefineAcceptedPaymentType();
    defineAcceptedPaymentTypesPage.addLoanFeesPaymentType(DefineAcceptedPaymentTypesPage.CHEQUE);
    adminPage = navigationHelper.navigateToAdminPage();
    defineAcceptedPaymentTypesPage = adminPage.navigateToDefineAcceptedPaymentType();
    defineAcceptedPaymentTypesPage.addLoanFeesPaymentType(DefineAcceptedPaymentTypesPage.VOUCHER);
    ApplyPaymentPage applyPaymentPage = navigationHelper.navigateToCenterViewDetailsPage(testCenterName).navigateToViewCenterChargesDetailPage().navigateToApplyPayments();
    // Then
    applyPaymentPage.verifyModeOfPayments();
}
Also used : CreateCenterEnterDataPage(org.mifos.test.acceptance.framework.center.CreateCenterEnterDataPage) MeetingParameters(org.mifos.test.acceptance.framework.center.MeetingParameters) ApplyPaymentPage(org.mifos.test.acceptance.framework.loan.ApplyPaymentPage) AdminPage(org.mifos.test.acceptance.framework.admin.AdminPage) NavigationHelper(org.mifos.test.acceptance.framework.testhelpers.NavigationHelper) DefineAcceptedPaymentTypesPage(org.mifos.test.acceptance.framework.admin.DefineAcceptedPaymentTypesPage) Test(org.testng.annotations.Test)

Example 38 with NavigationHelper

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

the class ImportTransactionsTest method importExcelFormatAudiBankTransactions.

@SuppressWarnings("PMD.SignatureDeclareThrowsException")
@Test(enabled = true)
public void importExcelFormatAudiBankTransactions() throws Exception {
    pluginsUtil.loadPlugin();
    navigationHelper = new NavigationHelper(selenium);
    String importFile = this.getClass().getResource("/AudiUSD-SevenTransactions.xls").toString();
    initRemote.dataLoadAndCacheRefresh(dbUnitUtilities, "mpesa_export_dbunit.xml", dataSource, selenium);
    importTransaction(importFile, EXCEL_IMPORT_TYPE);
    // TODO - add proper UI verifications and enable this test after MIFOS-4651 is fixed
    (new MifosPage(selenium)).logout();
    pluginsUtil.unloadPlugin();
}
Also used : NavigationHelper(org.mifos.test.acceptance.framework.testhelpers.NavigationHelper) MifosPage(org.mifos.test.acceptance.framework.MifosPage) Test(org.testng.annotations.Test)

Example 39 with NavigationHelper

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

the class ImportTransactionsTest method importTransactionPageLoad.

//  Test the import transaction page loads with no plugins available  - regression test for MIFOS-2683
@SuppressWarnings("PMD.SignatureDeclareThrowsException")
@Test(enabled = true, groups = "no_db_unit")
public void importTransactionPageLoad() throws Exception {
    navigationHelper = new NavigationHelper(selenium);
    String tempFileName = pluginsUtil.movePluginToTemp();
    AdminPage adminPage = navigationHelper.navigateToAdminPage();
    ImportTransactionsPage importTransactionsPage = adminPage.navigateToImportTransactionsPage();
    importTransactionsPage.verifyPage();
    pluginsUtil.movePluginFromTemp(tempFileName);
    (new MifosPage(selenium)).logout();
}
Also used : AdminPage(org.mifos.test.acceptance.framework.admin.AdminPage) NavigationHelper(org.mifos.test.acceptance.framework.testhelpers.NavigationHelper) ImportTransactionsPage(org.mifos.test.acceptance.framework.admin.ImportTransactionsPage) MifosPage(org.mifos.test.acceptance.framework.MifosPage) Test(org.testng.annotations.Test)

Example 40 with NavigationHelper

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

the class LoanImportTest method setUp.

@Override
@BeforeMethod
public void setUp() throws Exception {
    super.setUp();
    loanProductTestHelper = new LoanProductTestHelper(selenium);
    adminTestHelper = new AdminTestHelper(selenium);
    navigationHelper = new NavigationHelper(selenium);
}
Also used : NavigationHelper(org.mifos.test.acceptance.framework.testhelpers.NavigationHelper) LoanProductTestHelper(org.mifos.test.acceptance.loanproduct.LoanProductTestHelper) AdminTestHelper(org.mifos.test.acceptance.framework.testhelpers.AdminTestHelper) BeforeMethod(org.testng.annotations.BeforeMethod)

Aggregations

NavigationHelper (org.mifos.test.acceptance.framework.testhelpers.NavigationHelper)70 BeforeMethod (org.testng.annotations.BeforeMethod)42 LoanTestHelper (org.mifos.test.acceptance.framework.testhelpers.LoanTestHelper)23 DateTime (org.joda.time.DateTime)22 DateTimeUpdaterRemoteTestingService (org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService)20 LoanProductTestHelper (org.mifos.test.acceptance.loanproduct.LoanProductTestHelper)13 TestDataSetup (org.mifos.test.acceptance.util.TestDataSetup)10 CustomPropertiesHelper (org.mifos.test.acceptance.framework.testhelpers.CustomPropertiesHelper)9 Test (org.testng.annotations.Test)9 FeeTestHelper (org.mifos.test.acceptance.admin.FeeTestHelper)6 AdminPage (org.mifos.test.acceptance.framework.admin.AdminPage)6 LoanAccountPage (org.mifos.test.acceptance.framework.loan.LoanAccountPage)6 SubmitFormParameters (org.mifos.test.acceptance.framework.loanproduct.DefineNewLoanProductPage.SubmitFormParameters)6 QuestionGroupTestHelper (org.mifos.test.acceptance.framework.testhelpers.QuestionGroupTestHelper)6 DefineNewLoanProductPage (org.mifos.test.acceptance.framework.loanproduct.DefineNewLoanProductPage)5 Random (java.util.Random)4 AppLauncher (org.mifos.test.acceptance.framework.AppLauncher)4 GroupTestHelper (org.mifos.test.acceptance.framework.testhelpers.GroupTestHelper)4 SavingsAccountHelper (org.mifos.test.acceptance.framework.testhelpers.SavingsAccountHelper)4 DefineAcceptedPaymentTypesPage (org.mifos.test.acceptance.framework.admin.DefineAcceptedPaymentTypesPage)3