Exemple #1
0
        /// <summary>
        /// This method click on the Footer Dashboard Link
        /// </summary>
        public void ClickFooterDashboardLink()
        {
            Page_HAPrompt hAPrompt = new Page_HAPrompt();

            Thread.Sleep(6000);
            SeleniumKeywords.Click(pageName, "fdashboardlnk");
            hAPrompt.GoToDashboard();
        }
Exemple #2
0
        public void ValidateReportBottomLinks(string clientname, string pageName1)
        {
            if (IsCoachingEnable(clientname))
            {
                clientname = "Health Trust";
            }
            else
            {
                //clientname = "Onlife Health";
            }
            List <string[]> reportbottomlinks = CSVReaderDataTable.GetCSVData("ProgressCheckinReportData", pageName1, "reportbottomlinks", clientname);

            for (int i = 0; i < reportbottomlinks.Count; i++)
            {
                string reportbottomlinklocatorname = reportbottomlinks.ElementAt(i)[3];
                string explinktext    = reportbottomlinks.ElementAt(i)[4];
                string actuallinktext = SeleniumKeywords.GetText("CommonProgressCheckIn", reportbottomlinklocatorname);

                softAssertions.Add("Element : " + reportbottomlinklocatorname, explinktext, actuallinktext, "contains");


                SeleniumKeywords.Click("CommonProgressCheckIn", reportbottomlinklocatorname);
                if (explinktext == "RETURN TO DASHBOARD")
                {
                    Page_HAPrompt pha = new Page_HAPrompt();
                    pha.GoToDashboard();
                }
                string report_bootomlinks_locatorclass    = reportbottomlinks.ElementAt(i)[5];
                string navigated_page_element_locatorname = reportbottomlinks.ElementAt(i)[6];
                string exp_navigated_page_elementtext     = reportbottomlinks.ElementAt(i)[7];
                string actual_navigated_page_elementtext  = SeleniumKeywords.GetText(report_bootomlinks_locatorclass, navigated_page_element_locatorname);

                softAssertions.Add("Element : " + navigated_page_element_locatorname, exp_navigated_page_elementtext, actual_navigated_page_elementtext, "equals");
                Console.WriteLine("Element: " + navigated_page_element_locatorname + " " + exp_navigated_page_elementtext + " " + actual_navigated_page_elementtext);
                if (explinktext != "RETURN TO DASHBOARD")
                {
                    SeleniumKeywords.NavigateToPreviousPage();
                }
            }
        }