public void UserEntersValidValuesInCreateAccountingPeriodForm()
 {
     if (contrLang.LanguageDropDown().Text.Contains("EN"))
     {
         AdminAccountingPeriods.MonthSel().SendKeys(month_select);
         AdminAccountingPeriods.ClearAccPeriodAllFields();
         AdminAccountingPeriods.CreateClaimIssueData().SendKeys(AdminAccountingPeriods.MonthSel().GetAttribute("value") + "/1/" + year);
         AdminAccountingPeriods.CreateClaimPaymentData().SendKeys(AdminAccountingPeriods.MonthSel().GetAttribute("value") + "/28/" + year);
         AdminAccountingPeriods.AccPeriodsCreateYear().Click();
         AdminAccountingPeriods.AccPeriodsCreateYear().SendKeys(year);
         //AdminAccountingPeriods.ActiveCheckbox().Click();
         AdminAccountingPeriods.CreateAccButton().Click();
         Assert.AreEqual("http://intnstest:50080/AccountingPeriods", Driver.Url);
     }
     else
     {
         AdminAccountingPeriods.MonthSel().SendKeys(month_select_rs);
         AdminAccountingPeriods.ClearAccPeriodAllFields();
         AdminAccountingPeriods.CreateClaimIssueData().SendKeys("1." + AdminAccountingPeriods.MonthSel().GetAttribute("value") + "." + year + ".");
         AdminAccountingPeriods.CreateClaimPaymentData().SendKeys("28." + AdminAccountingPeriods.MonthSel().GetAttribute("value") + "." + year + ".");
         AdminAccountingPeriods.AccPeriodsCreateYear().Click();
         AdminAccountingPeriods.AccPeriodsCreateYear().SendKeys(year);
         //AdminAccountingPeriods.ActiveCheckbox().Click();
         AdminAccountingPeriods.CreateAccButton().Click();
         Assert.AreEqual("http://intnstest:50080/AccountingPeriods", Driver.Url);
     }
 }
 public void ErrorMessageIsShowed8()
 {
     if (contrLang.LanguageDropDown().Text.Contains("EN"))
     {
         Assert.AreEqual(expectedMessage18, AdminClaimCategory.EmptyClaimCategory().Text);
     }
     else
     {
         Assert.AreEqual(expectedMessageRS22, AdminClaimCategory.EmptyClaimCategory().Text);
     }
 }
Exemple #3
0
 public void ErrorMessageUnderAccNumInputIsShowed()
 {
     if (contrLang.LanguageDropDown().Text.Contains("EN"))
     {
         Assert.AreEqual(message15, ContrClaims.emptyCreateClaimAccNumberToPay().Text);
     }
     else
     {
         Assert.AreEqual(messageRS13, ContrClaims.emptyCreateClaimAccNumberToPay().Text);
     }
 }
 public void ErrorMessagesAreShowed10()
 {
     if (contrLang.LanguageDropDown().Text.Contains("EN"))
     {
         Assert.AreEqual(expectedMessage22, EditProfileAdmin.EmptyProfileName().Text);
         Assert.AreEqual(expectedMessage23, EditProfileAdmin.EmptyProfileLastName().Text);
     }
     else
     {
         Assert.AreEqual(expectedMessageRS1, EditProfileAdmin.EmptyProfileName().Text);
         Assert.AreEqual(expectedMessageRS2, EditProfileAdmin.EmptyProfileLastName().Text);
     }
 }
Exemple #5
0
        public void SearchNewCreatedClaim()
        {
            claim_categories2.FilterSearchButton().Click();
            SelectElement searchCrit = new SelectElement(claim_categories2.SearchCriteria());

            searchCrit.SelectByValue("Account number to pay");
            claim_categories2.SearchInput().SendKeys(acc_num_claim);
            claim_categories2.SearchSubmitButton().Click();
            Assert.AreEqual(acc_num_claim, claim_categories2.TableContractorClaims().FindElement(By.XPath("//td[5][contains(string(), '" + acc_num_claim + "')]")).Text);
            claim_categories2.FilterSearchButton().Click();

            if (contrLang.LanguageDropDown().Text.Contains("EN"))
            {
                SelectElement accPerFrom = new SelectElement(claim_categories2.AccountingPeriodFrom());
                accPerFrom.SelectByValue("January 1990");
                SelectElement accPerTo = new SelectElement(claim_categories2.AccountingPeriodTo());
                accPerTo.SelectByValue("December 2100");
            }
            else
            {
                SelectElement accPerFrom = new SelectElement(claim_categories2.AccountingPeriodFrom());
                accPerFrom.SelectByValue("januar 1990");
                SelectElement accPerTo = new SelectElement(claim_categories2.AccountingPeriodTo());
                accPerTo.SelectByValue("decembar 2100");
            }
            claim_categories2.UsernameFilterInput().SendKeys("IQService.contractor2");
            claim_categories2.TotalFrom().SendKeys("0");
            claim_categories2.TotalTo().SendKeys("50000");
            claim_categories2.FilterSubmitButton().Click();
        }
Exemple #6
0
        public void MessageUnderInputIsShowed()
        {
            LanguageContractor contrLang = new LanguageContractor(Driver);

            if (contrLang.LanguageDropDown().Text.Contains("EN"))
            {
                Assert.AreEqual(message13, ContrClaimsPage.emptyCreateClaimAccNumberToPay().Text);
            }
            else
            {
                Assert.AreEqual(messageRS13, ContrClaimsPage.emptyCreateClaimAccNumberToPay().Text);
            }
        }
Exemple #7
0
 public void MessageUnderInputIsShowed2()
 {
     if (contrLang.LanguageDropDown().Text.Contains("EN"))
     {
         Assert.AreEqual(message14, ContrClaimsPage.emptyCreateClaimAccNumberToPay().Text);
         Assert.AreEqual(message17, ContrClaimsPage.UniqueError().Text);
         Assert.AreEqual(message17, ContrClaimsPage.MonthlyClaimError().Text);
         Assert.AreEqual(message17, ContrClaimsPage.BicycleError().Text);
     }
     else
     {
         Assert.AreEqual(messageRS14, ContrClaimsPage.emptyCreateClaimAccNumberToPay().Text);
         Assert.AreEqual(messageRS15, ContrClaimsPage.UniqueError().Text);
         Assert.AreEqual(messageRS15, ContrClaimsPage.MonthlyClaimError().Text);
         Assert.AreEqual(messageRS15, ContrClaimsPage.BicycleError().Text);
     }
 }
Exemple #8
0
 public void ErrorMessagesAreShowed6()
 {
     if (contrLang.LanguageDropDown().Text.Contains("EN"))
     {
         Assert.AreEqual(expectedMessage10, AdminAccountingPeriods.EmptyCreateYear().Text);
         Assert.AreEqual(expectedMessage11, AdminAccountingPeriods.EmptyCreateClaimIssue().Text);
         Assert.AreEqual(expectedMessage12, AdminAccountingPeriods.EmptyCreateClaimPayment().Text);
     }
     else
     {
         Assert.AreEqual(expectedMessageRS20, AdminAccountingPeriods.EmptyCreateYear().Text);
         Assert.AreEqual(expectedMessageRS15, AdminAccountingPeriods.EmptyCreateClaimIssue().Text);
         Assert.AreEqual(expectedMessageRS16, AdminAccountingPeriods.EmptyCreateClaimPayment().Text);
     }
 }
Exemple #9
0
        public void ErrorMessagesAreShowedUnderInputs()
        {
            LanguageContractor contrLang = new LanguageContractor(Driver);

            if (contrLang.LanguageDropDown().Text.Contains("EN"))
            {
                Assert.AreEqual(message1, contractorProfile.EmptyAddressField().Text);
                Assert.AreEqual(message2, contractorProfile.EmptyBankNameField().Text);
                Assert.AreEqual(message3, contractorProfile.EmptyAccNumberContrField().Text);
                Assert.AreEqual(message4, contractorProfile.EmptyAgencyNameField().Text);
                Assert.AreEqual(message5, contractorProfile.EmptyTelephoneField().Text);
            }
            else
            {
                Assert.AreEqual(messageRS1, contractorProfile.EmptyAddressField().Text);
                Assert.AreEqual(messageRS2, contractorProfile.EmptyBankNameField().Text);
                Assert.AreEqual(messageRS3, contractorProfile.EmptyAccNumberContrField().Text);
                Assert.AreEqual(messageRS4, contractorProfile.EmptyAgencyNameField().Text);
                Assert.AreEqual(messageRS5, contractorProfile.EmptyTelephoneField().Text);
            }
        }
 public void ErrorMessagesAreShowedTest()
 {
     if (contrLang.LanguageDropDown().Text.Contains("EN"))
     {
         Assert.AreEqual(expectedMessage1, adminContraCreate.EmptyUsernameField1().Text);
         Assert.AreEqual(expectedMessage2, adminContraCreate.EmptyPCCIdField1().Text);
         Assert.AreEqual(expectedMessage3, adminContraCreate.EmptyFirstnameField1().Text);
         Assert.AreEqual(expectedMessage4, adminContraCreate.EmptyLastnameField1().Text);
     }
     else
     {
         Assert.AreEqual(expectedMessageRS5, adminContraCreate.EmptyUsernameField1().Text);
         Assert.AreEqual(expectedMessageRS6, adminContraCreate.EmptyPCCIdField1().Text);
         Assert.AreEqual(expectedMessageRS7, adminContraCreate.EmptyFirstnameField1().Text);
         Assert.AreEqual(expectedMessageRS8, adminContraCreate.EmptyLastnameField1().Text);
     }
 }
Exemple #11
0
 public void ErrorMessagesAreShowedUnderInputs2()
 {
     if (contrLang.LanguageDropDown().Text.Contains("EN"))
     {
         Assert.AreEqual(message6, contractorProfile.EmptyAddressField().Text);
         Assert.AreEqual(message7, contractorProfile.EmptyBankNameField().Text);
         Assert.AreEqual(message8, contractorProfile.EmptyAccNumberContrField().Text);
         Assert.AreEqual(message9, contractorProfile.EmptyAgencyNameField().Text);
         Assert.AreEqual(message10, contractorProfile.EmptyRegistryNumber().Text);
         Assert.AreEqual(message11, contractorProfile.EmptyTaxIdentification().Text);
         Assert.AreEqual(message12, contractorProfile.EmptyTelephoneField().Text);
     }
     else
     {
         Assert.AreEqual(messageRS6, contractorProfile.EmptyAddressField().Text);
         Assert.AreEqual(messageRS7, contractorProfile.EmptyBankNameField().Text);
         Assert.AreEqual(messageRS8, contractorProfile.EmptyAccNumberContrField().Text);
         Assert.AreEqual(messageRS9, contractorProfile.EmptyAgencyNameField().Text);
         Assert.AreEqual(messageRS10, contractorProfile.EmptyRegistryNumber().Text);
         Assert.AreEqual(messageRS11, contractorProfile.EmptyTaxIdentification().Text);
         Assert.AreEqual(messageRS12, contractorProfile.EmptyTelephoneField().Text);
     }
 }
 public void UserEntersValidValuesInCreateAccountingPeriodForm()
 {
     if (contrLang.LanguageDropDown().Text.Contains("EN"))
     {
         AccountingPeriodsPage.MonthSel().SendKeys(month_select);
         AccountingPeriodsPage.ClearAccPeriodAllFields();
         AccountingPeriodsPage.CreateClaimIssueData().SendKeys(AccountingPeriodsPage.MonthSel().GetAttribute("value") + "/1/" + year);
         AccountingPeriodsPage.CreateClaimPaymentData().SendKeys(AccountingPeriodsPage.MonthSel().GetAttribute("value") + "/28/" + year);
         AccountingPeriodsPage.AccPeriodsCreateYear().Click();
         AccountingPeriodsPage.AccPeriodsCreateYear().SendKeys(year);
         //AccountingPeriodsPage.ActiveCheckbox().Click();
         AccountingPeriodsPage.CreateAccButton().Click();
         Assert.AreEqual("http://intnstest:50080/AccountingPeriods", Driver.Url);
         Assert.AreEqual(month_select + " " + year, AccountingPeriodsPage.TableAccPeriod().FindElement(By.XPath("//td[1][contains(string(), '" + month_select + " " + year + "')]")).Text);
     }
     else
     {
         AccountingPeriodsPage.MonthSel().SendKeys(month_select_rs);
         AccountingPeriodsPage.ClearAccPeriodAllFields();
         AccountingPeriodsPage.CreateClaimIssueData().SendKeys("1." + AccountingPeriodsPage.MonthSel().GetAttribute("value") + "." + year + ".");
         AccountingPeriodsPage.CreateClaimPaymentData().SendKeys("28." + AccountingPeriodsPage.MonthSel().GetAttribute("value") + "." + year + ".");
         AccountingPeriodsPage.AccPeriodsCreateYear().Click();
         AccountingPeriodsPage.AccPeriodsCreateYear().SendKeys(year);
         //AccountingPeriodsPage.ActiveCheckbox().Click();
         AccountingPeriodsPage.CreateAccButton().Click();
         Assert.AreEqual("http://intnstest:50080/AccountingPeriods", Driver.Url);
         Assert.AreEqual(month_select_rs + " " + year, AccountingPeriodsPage.TableAccPeriod().FindElement(By.XPath("//td[1][contains(string(), '" + month_select_rs + " " + year + "')]")).Text);
     }
 }
 public void AdminClicsOnRsOption()
 {
     AdminhomePage5.LanguageButton().Click();
     AdminhomePage5.RSOption().Click();
     Assert.That(contrLang.LanguageDropDown().Text.Contains("RS"), Is.True, "Application is on English Language.");
 }