Search in sources :

Example 1 with DateTimeUpdaterRemoteTestingService

use of org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService in project head by mifos.

the class SavingsDepositTest method setUp.

@Override
// one of the dependent methods throws Exception
@SuppressWarnings("PMD.SignatureDeclareThrowsException")
@BeforeMethod
public void setUp() throws Exception {
    super.setUp();
    DateTimeUpdaterRemoteTestingService dateTimeUpdaterRemoteTestingService = new DateTimeUpdaterRemoteTestingService(selenium);
    DateTime targetTime = new DateTime(2009, 9, 9, 8, 0, 0, 0);
    dateTimeUpdaterRemoteTestingService.setDateTime(targetTime);
    savingsAccountHelper = new SavingsAccountHelper(selenium);
}
Also used : SavingsAccountHelper(org.mifos.test.acceptance.framework.testhelpers.SavingsAccountHelper) DateTimeUpdaterRemoteTestingService(org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService) DateTime(org.joda.time.DateTime) BeforeMethod(org.testng.annotations.BeforeMethod)

Example 2 with DateTimeUpdaterRemoteTestingService

use of org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService in project head by mifos.

the class SearchCustomerTest method tearDown.

@AfterMethod
public void tearDown() {
    (new MifosPage(selenium)).logout();
    new DateTimeUpdaterRemoteTestingService(selenium).resetDateTime();
}
Also used : MifosPage(org.mifos.test.acceptance.framework.MifosPage) DateTimeUpdaterRemoteTestingService(org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService) AfterMethod(org.testng.annotations.AfterMethod)

Example 3 with DateTimeUpdaterRemoteTestingService

use of org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService in project head by mifos.

the class WaiveLoanFeeTest method setUp.

@Override
// one of the dependent methods throws Exception
@SuppressWarnings("PMD.SignatureDeclareThrowsException")
@BeforeMethod
public void setUp() throws Exception {
    super.setUp();
    appLauncher = new AppLauncher(selenium);
    DateTimeUpdaterRemoteTestingService dateTimeUpdaterRemoteTestingService = new DateTimeUpdaterRemoteTestingService(selenium);
    DateTime targetTime = new DateTime(2011, 2, 28, 14, 0, 0, 0);
    dateTimeUpdaterRemoteTestingService.setDateTime(targetTime);
}
Also used : AppLauncher(org.mifos.test.acceptance.framework.AppLauncher) DateTimeUpdaterRemoteTestingService(org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService) DateTime(org.joda.time.DateTime) BeforeMethod(org.testng.annotations.BeforeMethod)

Example 4 with DateTimeUpdaterRemoteTestingService

use of org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService in project head by mifos.

the class CreateLSIMClientLoanAccountTest method setUp.

@Override
@SuppressWarnings("PMD.SignatureDeclareThrowsException")
// one of the dependent methods throws Exception
@BeforeMethod(alwaysRun = true)
public void setUp() throws Exception {
    super.setUp();
    applicationDatabaseOperation.updateLSIM(1);
    navigationHelper = new NavigationHelper(selenium);
    loanTestHelper = new LoanTestHelper(selenium);
    loanProductTestHelper = new LoanProductTestHelper(selenium);
    DateTimeUpdaterRemoteTestingService dateTimeUpdaterRemoteTestingService = new DateTimeUpdaterRemoteTestingService(selenium);
    DateTime targetTime = new DateTime(2010, 1, 22, 10, 55, 0, 0);
    dateTimeUpdaterRemoteTestingService.setDateTime(targetTime);
}
Also used : NavigationHelper(org.mifos.test.acceptance.framework.testhelpers.NavigationHelper) LoanProductTestHelper(org.mifos.test.acceptance.loanproduct.LoanProductTestHelper) DateTimeUpdaterRemoteTestingService(org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService) LoanTestHelper(org.mifos.test.acceptance.framework.testhelpers.LoanTestHelper) DateTime(org.joda.time.DateTime) BeforeMethod(org.testng.annotations.BeforeMethod)

Example 5 with DateTimeUpdaterRemoteTestingService

use of org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService in project head by mifos.

the class CreateLSIMClientLoanAccountTest method newMonthlyClientLoanAccountWithMeetingOnSameWeekAndWeekday.

@SuppressWarnings("PMD.SignatureDeclareThrowsException")
// https://mifosforge.jira.com/browse/MIFOS-5852
@Test(enabled = true)
public void newMonthlyClientLoanAccountWithMeetingOnSameWeekAndWeekday() throws Exception {
    //Given
    DateTimeUpdaterRemoteTestingService dateTimeUpdaterRemoteTestingService = new DateTimeUpdaterRemoteTestingService(selenium);
    DateTime targetTime = new DateTime(2010, 5, 22, 10, 55, 0, 0);
    dateTimeUpdaterRemoteTestingService.setDateTime(targetTime);
    //Then
    CreateLoanAccountSearchParameters searchParameters = new CreateLoanAccountSearchParameters();
    searchParameters.setSearchString("Monthly3rdFriday");
    searchParameters.setLoanProduct("MonthlyClientFlatLoanThirdFridayOfMonth");
    expectedDate = "08-Jul-2010";
    CreateLoanAccountSubmitParameters submitAccountParameters = new CreateLoanAccountSubmitParameters();
    submitAccountParameters.setAmount("2765.0");
    submitAccountParameters.setLoanPurpose("0008-Animal Trading");
    // create LSIM loan that has repayments on 2nd Thursday of each month
    submitAccountParameters.setLsimFrequencyMonths("on");
    submitAccountParameters.setLsimMonthTypeNthWeekdayOfMonth("on");
    submitAccountParameters.setLsimMonthRank("Second");
    submitAccountParameters.setLsimWeekDay("Thursday");
    submitAccountParameters.setLoanPurpose("0010-Camel");
    createLSIMLoanAndCheckAmountAndInstallmentDate(searchParameters, submitAccountParameters, expectedDate);
}
Also used : CreateLoanAccountSearchParameters(org.mifos.test.acceptance.framework.loan.CreateLoanAccountSearchParameters) CreateLoanAccountSubmitParameters(org.mifos.test.acceptance.framework.loan.CreateLoanAccountSubmitParameters) DateTimeUpdaterRemoteTestingService(org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService) DateTime(org.joda.time.DateTime) Test(org.testng.annotations.Test)

Aggregations

DateTimeUpdaterRemoteTestingService (org.mifos.test.acceptance.remote.DateTimeUpdaterRemoteTestingService)103 DateTime (org.joda.time.DateTime)81 BeforeMethod (org.testng.annotations.BeforeMethod)41 Test (org.testng.annotations.Test)22 LoanTestHelper (org.mifos.test.acceptance.framework.testhelpers.LoanTestHelper)21 NavigationHelper (org.mifos.test.acceptance.framework.testhelpers.NavigationHelper)20 CreateLoanAccountSearchParameters (org.mifos.test.acceptance.framework.loan.CreateLoanAccountSearchParameters)19 LoanAccountPage (org.mifos.test.acceptance.framework.loan.LoanAccountPage)16 DisburseLoanParameters (org.mifos.test.acceptance.framework.loan.DisburseLoanParameters)10 CreateLoanAccountSubmitParameters (org.mifos.test.acceptance.framework.loan.CreateLoanAccountSubmitParameters)9 SavingsAccountDetailPage (org.mifos.test.acceptance.framework.savings.SavingsAccountDetailPage)9 MifosPage (org.mifos.test.acceptance.framework.MifosPage)8 DepositWithdrawalSavingsParameters (org.mifos.test.acceptance.framework.savings.DepositWithdrawalSavingsParameters)8 SavingsProductParameters (org.mifos.test.acceptance.framework.savingsproduct.SavingsProductParameters)8 AfterMethod (org.testng.annotations.AfterMethod)8 CustomPropertiesHelper (org.mifos.test.acceptance.framework.testhelpers.CustomPropertiesHelper)7 EditAccountStatusParameters (org.mifos.test.acceptance.framework.account.EditAccountStatusParameters)6 SubmitFormParameters (org.mifos.test.acceptance.framework.loanproduct.DefineNewLoanProductPage.SubmitFormParameters)6 SavingsAccountHelper (org.mifos.test.acceptance.framework.testhelpers.SavingsAccountHelper)6 AppLauncher (org.mifos.test.acceptance.framework.AppLauncher)5