use of org.mifos.test.acceptance.framework.testhelpers.NavigationHelper in project head by mifos.
the class DecliningPrincipleLoanTest method setUp.
@Override
// one of the dependent methods throws Exception
@SuppressWarnings("PMD.SignatureDeclareThrowsException")
@BeforeMethod
public void setUp() throws Exception {
super.setUp();
navigationHelper = new NavigationHelper(selenium);
loanTestHelper = new LoanTestHelper(selenium);
propertiesHelper = new CustomPropertiesHelper(selenium);
loanProductTestHelper = new LoanProductTestHelper(selenium);
systemDateTime = new DateTime(2010, 10, 11, 10, 0, 0, 0);
TestDataSetup dataSetup = new TestDataSetup(selenium, applicationDatabaseOperation);
loanTestHelper.setApplicationTime(systemDateTime);
dataSetup.addDecliningPrincipalBalance();
}
use of org.mifos.test.acceptance.framework.testhelpers.NavigationHelper in project head by mifos.
the class HolidayTest method setUp.
@Override
// one of the dependent methods throws Exception
@SuppressWarnings("PMD.SignatureDeclareThrowsException")
@BeforeMethod
public void setUp() throws Exception {
super.setUp();
dateTimeUpdaterRemoteTestingService = new DateTimeUpdaterRemoteTestingService(selenium);
navigationHelper = new NavigationHelper(selenium);
loanTestHelper = new LoanTestHelper(selenium);
holidayTestHelper = new HolidayTestHelper(selenium);
appLauncher = new AppLauncher(selenium);
}
use of org.mifos.test.acceptance.framework.testhelpers.NavigationHelper in project head by mifos.
the class CenterTest method verifyApplyPaymentForCenterWithUnusualName.
@Test(enabled = true)
public void verifyApplyPaymentForCenterWithUnusualName() {
String centerName = "`~!@#$%^&*()_+-=[];',./{}|:<>? Center";
CreateCenterEnterDataPage.SubmitFormParameters formParameters = new CreateCenterEnterDataPage.SubmitFormParameters();
formParameters.setCenterName(centerName);
formParameters.setLoanOfficer("loan officer");
MeetingParameters meeting = MeetingParameters.getRandomMeetingParameters();
formParameters.setMeeting(meeting);
centerTestHelper.createCenter(formParameters, "MyOfficeDHMFT");
NavigationHelper navigationHelper = new NavigationHelper(selenium);
ViewCenterChargesDetailPage viewCenterChargesDetailPage = navigationHelper.navigateToCenterViewDetailsPage(centerName).navigateToViewCenterChargesDetailPage();
ApplyChargesPage applyChargesPage = viewCenterChargesDetailPage.navigateToApplyCharges();
ChargeParameters chargeParameters = new ChargeParameters();
chargeParameters.setAmount("100");
chargeParameters.setType(ChargeParameters.MISC_FEES);
viewCenterChargesDetailPage = applyChargesPage.applyChargeAndNaviagteToViewCenterChargesDetailPage(chargeParameters);
ApplyPaymentPage applyPaymentPage = viewCenterChargesDetailPage.navigateToApplyPayments();
PaymentParameters parameters = new PaymentParameters();
DateTime dateTime = new DateTime();
parameters.setAmount("100");
parameters.setTransactionDateDD(Integer.toString(dateTime.getDayOfMonth()));
parameters.setTransactionDateMM(Integer.toString(dateTime.getMonthOfYear()));
parameters.setTransactionDateYYYY(Integer.toString(dateTime.getYear()));
parameters.setPaymentType(PaymentParameters.CASH);
ApplyPaymentConfirmationPage applyPaymentConfirmationPage = applyPaymentPage.submitAndNavigateToApplyPaymentConfirmationPage(parameters);
//ElementPresent("css=form[name=applyPaymentActionForm]"));
Assert.assertEquals(true, applyPaymentConfirmationPage.getSelenium().isTextPresent("Review transaction"));
}
use of org.mifos.test.acceptance.framework.testhelpers.NavigationHelper in project head by mifos.
the class QuestionGroupLoanAccountTest method verifyKeyFinderInQuestionary.
@Test(enabled = true)
@SuppressWarnings("PMD.SignatureDeclareThrowsException")
public void verifyKeyFinderInQuestionary() {
NavigationHelper navigationHelper = new NavigationHelper(selenium);
QuestionGroupHelper questionGroupHelper = new QuestionGroupHelper(navigationHelper);
Random random = new Random();
boolean keyUnpressed = true;
boolean keyPressed = false;
String questionGroupTitle = "QG1" + random.nextInt(100);
String question1 = "DT_6245";
String choiceAnswer1 = "choiceTest13242";
String choiceAnswer2 = "choiceTest34003";
List<String> tag1 = new ArrayList<String>();
List<String> tag2 = new ArrayList<String>();
tag1.add("tag");
tag2.add("tag1");
questionGroupHelper.createQuestionGroupSmart(questionGroupTitle, "Create Loan", question1, choiceAnswer1, choiceAnswer2, tag1, tag2);
loanProductTestHelper.editLoanProductIncludeQuestionsGroups("ClientEmergencyLoan", questionGroupTitle);
CreateLoanAccountSearchParameters searchParameters = new CreateLoanAccountSearchParameters();
searchParameters.setSearchString("ClientWithLoan 20110221");
searchParameters.setLoanProduct("ClientEmergencyLoan");
CreateLoanAccountSubmitParameters submitAccountParameters = new CreateLoanAccountSubmitParameters();
submitAccountParameters.setAmount("1012.0");
LoanTestHelper loanTestHelper = new LoanTestHelper(selenium);
CreateLoanAccountEntryPage createLoanAccountEntryPage = loanTestHelper.navigateToCreateLoanAccountEntryPage(searchParameters);
createLoanAccountEntryPage.submitAndNavigateToQuestionResponsePage();
searchParameters.setSearchString("ClientWithLoan 20110221");
Assert.assertEquals((boolean) createLoanAccountEntryPage.isAnswerExist(keyUnpressed), true);
Assert.assertEquals((boolean) createLoanAccountEntryPage.isAnswerExist(keyPressed), false);
createLoanAccountEntryPage.setInputFilterChoices("2");
Assert.assertEquals((boolean) createLoanAccountEntryPage.isAnswerExist(keyPressed), true);
navigationHelper.navigateToAdminPage().navigateToViewAllQuestions().navigateToQuestionDetail(question1).navigateToEditQuestionPage().deactivate();
}
use of org.mifos.test.acceptance.framework.testhelpers.NavigationHelper in project head by mifos.
the class RemovePenaltiesTest method setUp.
@Override
@BeforeMethod
public void setUp() throws Exception {
super.setUp();
this.navigationHelper = new NavigationHelper(selenium);
this.penaltyHelper = new PenaltyHelper(selenium);
this.dateTimeUpdaterRemoteTestingService = new DateTimeUpdaterRemoteTestingService(selenium);
initRemote.dataLoadAndCacheRefresh(dbUnitUtilities, "acceptance_small_001_dbunit.xml", dataSource, selenium);
}
Aggregations