Esempio n. 1
0
        public void AddLoan_VerifyAddLoanAllFieldsAreMandatory()
        {
            try
            {
                test = extent.CreateTest("AddLoan_VerifyAddLoanAllFieldsAreMandatory").Info("Test Started");
                DebtSummaryPage    debt       = new DebtSummaryPage(BaseTest.driver);
                NavigationMenuPage navigation = new NavigationMenuPage(BaseTest.driver);
                AssetSummaryPage   funds      = new AssetSummaryPage(BaseTest.driver);
                Thread.Sleep(3000);
                funds.ClickDebtSummary();
                debt.AddLoan_TotalLoanCommitmentIsMandatory();
                String alert1 = debt.CaptureAlertMessage();
                Assert.IsTrue(alert1 == "All Fields are mandatory", "Loan can be addedd without commitment details");

                debt.AddLoan_OriginationDateIsMandatory();
                String alert2 = debt.CaptureAlertMessage();
                Assert.IsTrue(alert2 == "All Fields are mandatory", "Loan can be addedd without origination date details");

                debt.AddLoan_InitialMaturityIsMandatory();
                String alert3 = debt.CaptureAlertMessage();
                Assert.IsTrue(alert3 == "All Fields are mandatory", "Loan can be addedd without Initial Maturity details");

                debt.AddLoan_InterestRateTypeIsMandatory();
                String alert4 = debt.CaptureAlertMessage();
                Assert.IsTrue(alert4 == "All Fields are mandatory", "Loan can be addedd without interest rate details");
            }
            catch (Exception e)
            {
                test.Log(Status.Fail, "Test Case Failed");
                baseTest.TakeScreenshot();
                Console.WriteLine(e.StackTrace);
            }
        }
Esempio n. 2
0
        public void AddLoan_VerifyAddLoanAllDropdownFieldsAreMandatory()
        {
            try
            {
                test = extent.CreateTest("AddLoan_VerifyAddLoanAllDropdownFieldsAreMandatory").Info("Test Started");
                DebtSummaryPage    debt       = new DebtSummaryPage(BaseTest.driver);
                NavigationMenuPage navigation = new NavigationMenuPage(BaseTest.driver);
                AssetSummaryPage   funds      = new AssetSummaryPage(BaseTest.driver);
                Thread.Sleep(3000);
                funds.ClickDebtSummary();
                debt.AddLoan_LenderNameIsMandatory();
                String alert1 = debt.CaptureAlertMessage();
                Assert.IsTrue(alert1 == "All Fields are mandatory", "Loan can be addedd without lender details");

                debt.AddLoan_PropertyNameIsMandatory();
                String alert2 = debt.CaptureAlertMessage();
                Assert.IsTrue(alert2 == "All Fields are mandatory", "Loan can be addedd without property name details");

                debt.AddLoan_LoanTypeIsMandatory();
                String alert3 = debt.CaptureAlertMessage();
                Assert.IsTrue(alert3 == "All Fields are mandatory", "Loan can be addedd without loan type details");
            }
            catch (Exception e)
            {
                test.Log(Status.Fail, "Test Case Failed");
                baseTest.TakeScreenshot();
                Console.WriteLine(e.StackTrace);
            }
        }
Esempio n. 3
0
 public void DebtSummary_VerifyListViewColumnLabels_LastFive()
 {
     try
     {
         test = extent.CreateTest("DebtSummary_VerifyListViewColumnLabels_LastFive").Info("Test Started");
         DebtSummaryPage    debt       = new DebtSummaryPage(BaseTest.driver);
         NavigationMenuPage navigation = new NavigationMenuPage(BaseTest.driver);
         AssetSummaryPage   funds      = new AssetSummaryPage(BaseTest.driver);
         funds.ClickDebtSummary();
         debt.Debt_ChangeToListView();
         String label5 = navigation.ReturnListViewColumnLabel5();
         String label6 = navigation.ReturnListViewColumnLabel6();
         String label7 = navigation.ReturnListViewColumnLabel7();
         String label8 = navigation.ReturnListViewColumnLabel8();
         String label9 = navigation.ReturnListViewColumnLabel9();
         Assert.IsTrue(label5 == "Current Debt", $"Expected:'Current Debt' does not match Actual:{label5}");
         Assert.IsTrue(label6 == "Total Loan", $"Expected:'Total Loan' does not match Actual:{label6}");
         Assert.IsTrue(label7 == "Interest Rate", $"Expected:'Interest Rate' does not match Actual:{label7}");
         Assert.IsTrue(label8 == "Outstanding", $"Expected:'Outstanding' does not match Actual:{label8}");
         Assert.IsTrue(label9 == "Months To", $"Expected:'Outstanding Amount:' does not match Actual:{label9}");
     }
     catch (Exception e)
     {
         test.Log(Status.Fail, "Test Case Failed");
         baseTest.TakeScreenshot();
         Console.WriteLine(e.StackTrace);
     }
 }
Esempio n. 4
0
 public void DebtSummary_VerifyListViewColumnLabels_FirstFour()
 {
     try
     {
         test = extent.CreateTest("DebtSummary_VerifyListViewColumnLabels_FirstFour").Info("Test Started");
         DebtSummaryPage    debt       = new DebtSummaryPage(BaseTest.driver);
         NavigationMenuPage navigation = new NavigationMenuPage(BaseTest.driver);
         AssetSummaryPage   funds      = new AssetSummaryPage(BaseTest.driver);
         funds.ClickDebtSummary();
         debt.Debt_ChangeToListView();
         String label1 = navigation.ReturnListViewColumnLabel1();
         String label2 = navigation.ReturnListViewColumnLabel2();
         String label3 = navigation.ReturnListViewColumnLabel3();
         String label4 = navigation.ReturnListViewColumnLabel4();
         Assert.IsTrue(label1 == "Property Name", $"Expected:'Property Name' does not match Actual:{label1}");
         Assert.IsTrue(label2 == "Date Of Loan", $"Expected:'Date Of Loan' does not match Actual:{label2}");
         Assert.IsTrue(label3 == "Lender", $"Expected:'Lender' does not match Actual:{label3}");
         Assert.IsTrue(label4 == "Current Maturity", $"Expected:'Current Maturity' does not match Actual:{label4}");
     }
     catch (Exception e)
     {
         test.Log(Status.Fail, "Test Case Failed");
         baseTest.TakeScreenshot();
         Console.WriteLine(e.StackTrace);
     }
 }
Esempio n. 5
0
 public void DebtSummary_VerifyCardLabels()
 {
     try
     {
         test = extent.CreateTest("DebtSummary_VerifyCardLabels").Info("Test Started");
         DebtSummaryPage  debt  = new DebtSummaryPage(BaseTest.driver);
         AssetSummaryPage funds = new AssetSummaryPage(BaseTest.driver);
         funds.ClickDebtSummary();
         String label1 = debt.ReturnCardLabel1();
         String label2 = debt.ReturnCardLabel2();
         String label3 = debt.ReturnCardLabel3();
         String label4 = debt.ReturnCardLabel4();
         String label5 = debt.ReturnCardLabel5();
         String label6 = debt.ReturnCardLabel6();
         Assert.IsTrue(label1 == "Lender Name:", $"Expected:'Lender Name:' does not match Actual:{label1}");
         Assert.IsTrue(label2 == "Lender Type:", $"Expected:'Lender Type:' does not match Actual:{label2}");
         Assert.IsTrue(label3 == "Loan Type:", $"Expected:'Loan Type:' does not match Actual:{label3}");
         Assert.IsTrue(label4 == "Current Maturity:", $"Expected:'Current Maturity:' does not match Actual:{label4}");
         Assert.IsTrue(label5 == "Outstanding Amount:", $"Expected:'Outstanding Amount:' does not match Actual:{label5}");
         Assert.IsTrue(label6 == "Months To Maturity:", $"Expected:'Months To Maturity:' does not match Actual:{label6}");
     }
     catch (Exception e)
     {
         test.Log(Status.Fail, "Test Case Failed");
         baseTest.TakeScreenshot();
         Console.WriteLine(e.StackTrace);
     }
 }
Esempio n. 6
0
 public void DebtSummary_VerifyNewLoanDisplayedOnDebtSummary()
 {
     try
     {
         test = extent.CreateTest("DebtSummary_VerifyNewLoanDisplayedOnDebtSummary").Info("Test Started");
         DebtSummaryPage  debt  = new DebtSummaryPage(BaseTest.driver);
         AssetSummaryPage funds = new AssetSummaryPage(BaseTest.driver);
         Thread.Sleep(3000);
         funds.ClickDebtSummary();
         int numOfCardsBefore = debt.NumberOfCardsPresent();
         debt.AddLoanWithFixedInterest();
         debt.NavigateBackToDebt();
         driver.Navigate().Refresh();
         funds.ClickDebtSummary();
         int numOfCardsAfter = debt.NumberOfCardsPresent();
         Assert.IsTrue(numOfCardsBefore + 1 == numOfCardsAfter, "New loan created does not reflect on debt summary");
     }
     catch (Exception e)
     {
         test.Log(Status.Fail, "Test Case Failed");
         baseTest.TakeScreenshot();
         Console.WriteLine(e.StackTrace);
     }
 }