public void TC_VerifyResourcesSubMenuOptions() { //Page_Login plogin = new Page_Login(); //plogin.Login(); //Page_HAPrompt haprompt = new Page_HAPrompt(); //haprompt.GoToDashboard(); Common cmn = new Common(); cmn.ClickOnResources(); int optionno = 54; Page_Dashboard dashbrd = new Page_Dashboard(softassertions); List <String[]> popupmsg = CSVReaderDataTable.GetCSVData("LeftSubmenuContent", pageName, "resourcessubmenu", "allclients"); TestContext.WriteLine("Data: " + popupmsg.Count); dashbrd.Verify_LeftSubMenuOptions(popupmsg, optionno); List <String[]> specific_resourcessubmenu = CSVReaderDataTable.GetCSVData("LeftSubmenuContent", pageName, "specific_resourcessubmenu"); dashbrd.Verify_LeftSubMenuOptions(specific_resourcessubmenu, optionno); cmn.CloseHamMenu(); is_soft_assert = true; softassertions.AssertAll(); }
public void TC_VerifyCoachingSubMenuOptions() { //Page_Login plogin = new Page_Login(); //plogin.Login(); //Page_HAPrompt haprompt = new Page_HAPrompt(); //haprompt.GoToDashboard(); coachingEnabled = cmn.GetConfig("CoachingEnabled").ElementAt(0)[1].ToLower(); if (coachingEnabled.Equals("false")) { Assert.Ignore("Coaching not enabled for client"); } cmn.ClickGoalMenu(); int optionno = 16; Page_Dashboard dashbrd = new Page_Dashboard(softassertions); List <String[]> popupmsg = CSVReaderDataTable.GetCSVData("LeftSubmenuContent", pageName, "coachingsubmenu", "allclients"); dashbrd.Verify_LeftSubMenuOptions(popupmsg, optionno); cmn.CloseHamMenu(); is_soft_assert = true; softassertions.AssertAll(); }
public void TC_VerifyCourseSubMenuOptions() { //Page_Login plogin = new Page_Login(); //plogin.Login(); //Page_HAPrompt haprompt = new Page_HAPrompt(); //haprompt.GoToDashboard(); Common cmn = new Common(); cmn.ClickCourseMenu(); int optionno = 4; Page_Dashboard dashbrd = new Page_Dashboard(softassertions); List <String[]> coursesubmenu = CSVReaderDataTable.GetCSVData("LeftSubmenuContent", pageName, "coursessubmenu", "allclients"); dashbrd.Verify_LeftSubMenuOptions(coursesubmenu, optionno); List <String[]> specific_coursesubmenu = CSVReaderDataTable.GetCSVData("LeftSubmenuContent", pageName, "specific_coursessubmenu"); dashbrd.Verify_LeftSubMenuOptions(specific_coursesubmenu, optionno); cmn.CloseHamMenu(); is_soft_assert = true; softassertions.AssertAll(); }
public void TC_MaintainWeightGoal() { coachingEnabled = cmn.GetConfig("CoachingEnabled").ElementAt(0)[1].ToLower(); if (coachingEnabled.Equals("false")) { Assert.Ignore("Coaching not available for client"); } CommonGoals cmngoal = new CommonGoals(softassertions); Page_MaintainWeightGoal mt = new Page_MaintainWeightGoal(softassertions); //cmn.ClickGoalMenu(); mt.InputWeight(); cmngoal.ClickStep1NextBtn(); is_soft_assert = true; mt.VerifyPlanScreen(); mt.VerifyActionsAdded(); System.Threading.Thread.Sleep(3000); cmngoal.ClickStep2NextBtn(); mt.VerifySetUpScreen(); cmngoal.ClickConfirmBtn(); mt.VerifyGoalComplete(); cmngoal.ClickRemoveBtn(); cmngoal.VerifyRemovePopUp(); cmngoal.ClickRemoveScreenYesBtn(); Page_HAPrompt haprompt = new Page_HAPrompt(); haprompt.GoToDashboard(); Page_Dashboard dashbrd = new Page_Dashboard(); Assert.IsTrue(dashbrd.AtDashboard(), "Not Navigated to Dashboard"); }
public void TC_VerifyCustomLoginNucor() { //To call the Page Login Method if (GlobalVariables.clientname.ToLower().Equals("nucor")) { if ((GlobalVariables.environment.ToLower().Equals("prod")) || (GlobalVariables.environment.ToLower().Equals("Production"))) { SeleniumKeywords.NavigateToUrl("https://nucornuyou.com"); } else if ((GlobalVariables.environment.ToLower().Equals("staging")) || (GlobalVariables.environment.ToLower().Equals("sa"))) { SeleniumKeywords.NavigateToUrl("https://sa.nucornuyou.com"); } Page_Login plogin = new Page_Login(); System.Threading.Thread.Sleep(2000); plogin.CustomURLLogin(); Page_HAPrompt haprompt = new Page_HAPrompt(); Assert.IsTrue(haprompt.AtHaPrompt(), "Not at HA Prompt Page"); haprompt.GoToDashboard(); //To call the Page Login Method Page_Dashboard Dashboard = new Page_Dashboard(); Assert.IsTrue(Dashboard.AtDashboard()); Common logout = new Common(); logout.LogOut(); } else { Assert.Ignore("Feature is not avaibale for the client"); } }
public void TC_VerifyDevicesAndAppsSubMenuOptions() { List <string[]> isEnabled = cmn.GetConfig("FitnessDevice", "NutritionApp"); fitnessEnabled = isEnabled.ElementAt(0)[1].ToLower(); nutritionEnabled = isEnabled.ElementAt(0)[2].ToLower(); if (fitnessEnabled.Equals("false") && nutritionEnabled.Equals("false")) { Assert.Ignore("Device and Apps not available for Client"); } //Page_Login plogin = new Page_Login(); //plogin.Login(); //Page_HAPrompt haprompt = new Page_HAPrompt(); //haprompt.GoToDashboard(); if (GlobalVariables.clientname.ToLower().Equals("dollar general")) { Assert.Ignore("Feature not availabe for the client"); } else { cmn.ClickDevicesAndApps(); int optionno = 47; Page_Dashboard dashbrd = new Page_Dashboard(softassertions); List <String[]> devicesubmenu = CSVReaderDataTable.GetCSVData("LeftSubmenuContent", pageName, "devicesandappssubmenu", "allclients"); dashbrd.Verify_LeftSubMenuOptions(devicesubmenu, optionno); List <String[]> specific_devicesandappssubmenu = CSVReaderDataTable.GetCSVData("LeftSubmenuContent", pageName, "specific_devicesandappssubmenu"); dashbrd.Verify_LeftSubMenuOptions(specific_devicesandappssubmenu, optionno); //if (GlobalVariables.clientname.ToLower().Equals("health trust")) //{ // devicesubmenu = CSVReaderDataTable.GetCSVData("LeftmenuContent", pageName, "orderdevice_devicesandapppssubmenu", "Common"); ; // dashbrd.Verify_LeftSubMenuOptions(devicesubmenu, optionno); //} //if (!(GlobalVariables.clientname.ToLower().Equals("nucor"))) //{ // devicesubmenu = CSVReaderDataTable.GetCSVData("LeftmenuContent", pageName, "myfitness_devicesandapppssubmenu", "Common"); ; // dashbrd.Verify_LeftSubMenuOptions(devicesubmenu, optionno); //} //if (!(GlobalVariables.clientname.ToLower().Equals("comprehensivecoaching")) || !(GlobalVariables.clientname.ToLower().Equals("opt out satc")) || !(GlobalVariables.clientname.ToLower().Equals("physical activity")) || !(GlobalVariables.clientname.ToLower().Equals("self directed")) || !(GlobalVariables.clientname.ToLower().Equals("weight management")) || !(GlobalVariables.clientname.ToLower().Equals("first fleet"))) //{ // devicesubmenu = CSVReaderDataTable.GetCSVData("LeftmenuContent", pageName, "mynutrition_devicesandapppssubmenu", "Common"); ; // dashbrd.Verify_LeftSubMenuOptions(devicesubmenu, optionno); //} cmn.CloseHamMenu(); is_soft_assert = true; softassertions.AssertAll(); } }
public void TC_VerifySuccessfullRegistration() { is_soft_assert = false; //Navigate to Get Started Page Page_Registration reg = new Page_Registration(softassertions); reg.ClickGetStarted(); userinfo.Add(GlobalVariables.firstname); userinfo.Add(GlobalVariables.lastname); userinfo.Add(GlobalVariables.dob); userinfo.Add(GlobalVariables.zipcode); userinfo.Add(GlobalVariables.popseg1); userinfo.Add(GlobalVariables.ssn); // Enter details in get started page reg.FillGetStartedDetails(userinfo, additionalDetails); // Click User Agreement next button reg.ClickUAContinue(); isSSO = config.GetConfig("SSO"); //Update required fields reg.EnterRequiredFields(isSSO); //Click Save and Continue reg.ClickSaveAndContinue(); Page_HAPrompt haprompt = new Page_HAPrompt(); haprompt.GoToDashboard(); Page_Dashboard Dashboard = new Page_Dashboard(); //Verify At Dashboard page Assert.IsTrue(Dashboard.AtDashboard()); Common cmn = new Common(); string sso = isSSO.ElementAt(0)[1]; TestContext.WriteLine("SSO: " + sso); if (sso.ToLower().Equals("true")) { //Create User for SSO Clients reg.CreateUsernamePassword(); } //Log Out //Common cmn = new Common(); cmn.LogOut(); }
public void TC_VerifyEstream() { journeyEnabled = cmn.GetConfig("JourneyEnabled").ElementAt(0)[1].ToLower(); if (journeyEnabled.Equals("false")) { Assert.Ignore("Journeys not available for the client"); } Page_Dashboard dashbrd = new Page_Dashboard(); Assert.IsTrue(dashbrd.EstreamDisplayed(), "Recommendation section missing"); }
public void TC_VerifyLeftMenu() { Common cmn = new Common(); cmn.OpenHamMenu(); Page_Dashboard dashbrd = new Page_Dashboard(softassertions); menuitems = CSVReaderDataTable.GetCSVData("LeftmenuContent", "Dashboard", "menuitems", clientname); dashbrd.Verify_LeftMenuCommonOptions(menuitems); cmn.CloseHamMenu(); is_soft_assert = true; softassertions.AssertAll(); }
public void TC_VerifyTrackersSubMenu() { SeleniumKeywords.RefreshPage(); System.Threading.Thread.Sleep(3000); cmn.ClickTrackerMenu(); int optionno = 27; Page_Dashboard dashbrd = new Page_Dashboard(softassertions); List <String[]> popupmsg = CSVReaderDataTable.GetCSVData("LeftmenuContent", "Dashboard", "trackersubmenu", "Common"); dashbrd.Verify_LeftSubMenuOptions(popupmsg, optionno); is_soft_assert = true; softassertions.AssertAll(); }
public void TC_VerifyProgressCheckInSubMenu() { SeleniumKeywords.RefreshPage(); System.Threading.Thread.Sleep(3000); Common cmn = new Common(); cmn.ClickProgressCheckinMenu(); int optionno = 39; Page_Dashboard dashbrd = new Page_Dashboard(softassertions); List <String[]> popupmsg = CSVReaderDataTable.GetCSVData("LeftmenuContent", "Dashboard", "progresschechinsubmenu", "Common"); dashbrd.Verify_LeftSubMenuOptions(popupmsg, optionno); is_soft_assert = true; softassertions.AssertAll(); }
public void TC_VerifyLogout() { //To call the Page Login Method Page_Login plogin = new Page_Login(); plogin.Login(); Page_HAPrompt haprompt = new Page_HAPrompt(); haprompt.GoToDashboard(); Page_Dashboard Dashboard = new Page_Dashboard(); Assert.IsTrue(Dashboard.AtDashboard()); Common logout = new Common(); logout.LogOut(); }
public void TC_VerifyEstream() { if (journeyEnabled.Equals("false")) { Assert.Ignore("Journeys not available for the client"); } //Page_Login plogin = new Page_Login(); //plogin.Login(); //Page_HAPrompt haprompt = new Page_HAPrompt(); //haprompt.GoToDashboard(); Page_Dashboard dashbrd = new Page_Dashboard(); Assert.IsTrue(dashbrd.EstreamDisplayed(), "Explore section missing"); }
public void TC_VerifyAtDashboard() { clientname = GlobalVariables.clientname.ToLower(); Console.WriteLine("ClientName : " + clientname); //To call the Page Login Method Page_Login plogin = new Page_Login(); plogin.Login(); Page_HAPrompt haprompt = new Page_HAPrompt(); haprompt.GoToDashboard(); Page_Dashboard Dashboard = new Page_Dashboard(); Assert.IsTrue(Dashboard.AtDashboard()); }
public void TC_ForgotUserName() { //To call the Page Login Method Page_Login plogin = new Page_Login(); string username = plogin.forgotUserName(); Assert.AreEqual(GlobalVariables.username, username); Page_HAPrompt haprompt = new Page_HAPrompt(); //Assert.IsTrue(haprompt.AtHaPrompt(), "Not at HA Prompt Page"); haprompt.GoToDashboard(); //To call the Page Login Method Page_Dashboard Dashboard = new Page_Dashboard(); Assert.IsTrue(Dashboard.AtDashboard()); }
public void TC_VerifyUpdateProgressSection() { if (journeyEnabled.Equals("true")) { Assert.Ignore("Journeys available for the client"); } //Page_Login plogin = new Page_Login(); //plogin.Login(); //Page_HAPrompt haprompt = new Page_HAPrompt(); //haprompt.GoToDashboard(); Page_Dashboard pdb = new Page_Dashboard(softassertions); pdb.Verify_UpdateProgressSection(); is_soft_assert = true; softassertions.AssertAll(); }
public void TC_VerifyDashboardLink() { //To call the Page Login Method Page_Login plogin = new Page_Login(); plogin.Login(); Page_HAPrompt haprompt = new Page_HAPrompt(); haprompt.GoToDashboard(); Common dblink = new Common(); dblink.ClickFooterDashboardLink(); haprompt.GoToDashboard(); Page_Dashboard dashbrd = new Page_Dashboard(); Assert.IsTrue(dashbrd.JourneyBannerDisplayed(), "Journey Banner missing"); //Assert.Ignore("Test Case Disabled due to bug DEF - 2617"); }
public void TC_VerifyGoalSubMenu() { SeleniumKeywords.RefreshPage(); System.Threading.Thread.Sleep(3000); coachingEnabled = cmn.GetConfig("CoachingEnabled").ElementAt(0)[1].ToLower(); if (coachingEnabled.Equals("false")) { Assert.Ignore("Coaching not available for client"); } cmn.ClickGoalMenu(); int optionno = 16; Page_Dashboard dashbrd = new Page_Dashboard(softassertions); List <String[]> popupmsg = CSVReaderDataTable.GetCSVData("LeftmenuContent", "Dashboard", "coachingsubmenu", "Common"); dashbrd.Verify_LeftSubMenuOptions(popupmsg, optionno); is_soft_assert = true; softassertions.AssertAll(); }
public void TC_VerifyDevicesSubMenu() { SeleniumKeywords.RefreshPage(); System.Threading.Thread.Sleep(3000); List <string[]> isEnabled = cmn.GetConfig("FitnessDevice", "NutritionApp"); deviceEnabled = isEnabled.ElementAt(0)[1].ToLower(); nutritionEnabled = isEnabled.ElementAt(0)[2].ToLower(); if (deviceEnabled.Equals("false") && nutritionEnabled.Equals("false")) { Assert.Ignore("Device and Apps not available for client"); } if (GlobalVariables.isregistered.ToLower().Equals("false")) { Page_DevicesAndApps pdevice = new Page_DevicesAndApps(); pdevice.AcceptTOS(); } if (clientname.Equals("dollar general")) { Assert.Ignore("Feature no availabe for the client"); } else { cmn.ClickDevicesAndApps(); int optionno = 47; Page_Dashboard dashbrd = new Page_Dashboard(softassertions); List <String[]> popupmsg = null; if (clientname.Equals("health trust")) { popupmsg = CSVReaderDataTable.GetCSVData("LeftmenuContent", "Dashboard", "devicesandapppssubmenu", clientname); } else { popupmsg = CSVReaderDataTable.GetCSVData("LeftmenuContent", "Dashboard", "devicesandapppssubmenu", "Common"); } dashbrd.Verify_LeftSubMenuOptions(popupmsg, optionno); } }
public void TC_VerifyFirstModuleQuestions() { //To call the Page Login Method Page_Login plogin = new Page_Login(); plogin.Login(); Page_HAPrompt haprompt = new Page_HAPrompt(); //Assert.IsTrue(haprompt.AtHaPrompt(), "Not at HA Prompt Page"); haprompt.GoToDashboard(); //To call the Page Login Method Page_Dashboard Dashboard = new Page_Dashboard(); Assert.IsTrue(Dashboard.AtDashboard()); Page_NewHA ha = new Page_NewHA(softassertions); ha.FillHA(); }
public void TC_VerifyProgressCheckinSubMenuOptions() { //Page_Login plogin = new Page_Login(); //plogin.Login(); //Page_HAPrompt haprompt = new Page_HAPrompt(); //haprompt.GoToDashboard(); cmn.ClickProgressCheckinMenu(); int optionno = 39; Page_Dashboard dashbrd = new Page_Dashboard(softassertions); List <String[]> popupmsg = CSVReaderDataTable.GetCSVData("LeftSubmenuContent", pageName, "progresschechinsubmenu", "allclients"); dashbrd.Verify_LeftSubMenuOptions(popupmsg, optionno); cmn.CloseHamMenu(); is_soft_assert = true; softassertions.AssertAll(); }
public void TC_VerifyCoachingSection() { if (journeyEnabled.Equals("true")) { Assert.Ignore("Journeys available for the client"); } else if (coachingEnabled.Equals("false")) { Assert.Ignore("Coaching not enabled for client"); } //Page_Login plogin = new Page_Login(); //plogin.Login(); //Page_HAPrompt haprompt = new Page_HAPrompt(); //haprompt.GoToDashboard(); Page_Dashboard pdb = new Page_Dashboard(softassertions); pdb.Verify_CoachingSection(); is_soft_assert = true; softassertions.AssertAll(); }
public void TC_VerifyLeftMenuOptions() { //Page_Login plogin = new Page_Login(); //plogin.Login(); //Page_HAPrompt haprompt = new Page_HAPrompt(); //haprompt.GoToDashboard(); if (GlobalVariables.isregistered.ToLower().Equals("false")) { Page_DevicesAndApps pdevice = new Page_DevicesAndApps(); pdevice.AcceptTOS(); } Common cmn = new Common(); cmn.OpenHamMenu(); Page_Dashboard dashbrd = new Page_Dashboard(softassertions); //menuitems = CSVReaderDataTable.GetCSVData("LeftmenuContent", pageName, "menuitems", GlobalVariables.clientname); // if ((GlobalVariables.clientname.ToLower().Equals("health trust")) || (GlobalVariables.clientname.ToLower().Equals("meabt"))) //if ((GlobalVariables.clientname.ToLower().Equals("health trust"))) // { // dashbrd.Verify_LeftMenuOptionsOrder(menuitems); // } //else //{ menuitems = CSVReaderDataTable.GetCSVData("LeftmenuContent", pageName, "menuitems", "Common"); //Console.WriteLine("in else section"); dashbrd.Verify_LeftMenuCommonOptions(menuitems); menuitems = CSVReaderDataTable.GetCSVData("LeftmenuContent", pageName, "menuitems", GlobalVariables.clientname.ToLower()); dashbrd.Verify_LeftMenuCommonOptions(menuitems); //} cmn.CloseHamMenu(); is_soft_assert = true; softassertions.AssertAll(); }
public void TC_VerifyFooter() { SeleniumKeywords.RefreshPage(); System.Threading.Thread.Sleep(3000); //Common dblink = new Common(); cmn.ClickFooterDashboardLink(); Page_HAPrompt haprompt = new Page_HAPrompt(); haprompt.GoToDashboard(); Page_Dashboard dashbrd = new Page_Dashboard(); Assert.IsTrue(dashbrd.JourneyBannerDisplayed(), "Journey Banner missing"); Footer ftr = new Footer(); ftr.TC_VerifyTrackerLink(); ftr.TC_VerifyMyHealthLink(); if ((!clientname.Equals("arc")) || (!clientname.Equals("self directed"))) { //Assert.Ignore("Certificate is not available for " + clientname); Common hipaa = new Common(); hipaa.ClickFooterHipaaLink(); Page_HIPAA rights = new Page_HIPAA(); List <string[]> result = rights.VerifyHeader(); Assert.Multiple(() => { for (int i = 0; i < result.Count; i++) { Assert.IsTrue(Convert.ToBoolean(result.ElementAt(i)[1]), result.ElementAt(i)[0]); } } ); Assert.IsTrue(rights.VerifyContentSectionPresent(), "HIPAA Rights content not found"); } ftr.TC_VerifyPrivacyPolLink(); ftr.TC_VerifyTOSLink(); ftr.TC_VerifyCertificateLnk(); ftr.TC_VerifyFeedbackLink(); }
public void TC_VerifyfooterLinksPresent() { //Page_Login plogin = new Page_Login(); //plogin.Login(); //Page_HAPrompt haprompt = new Page_HAPrompt(); //haprompt.GoToDashboard(); Page_Dashboard footer = new Page_Dashboard(softassertions); List <string[]> FooterElements = CSVReaderDataTable.GetCSVData("DashboardData", pageName, "commonfooterlink", "Common"); footer.CommonFooterLinksDisplayed(FooterElements); //footer. List <string[]> clientFooterElements = CSVReaderDataTable.GetCSVData("DashboardData", pageName, "footerlink", GlobalVariables.clientname); footer.CommonFooterLinksDisplayed(FooterElements); footer.ClientFooterLinksDisplayed(clientFooterElements); is_soft_assert = true; softassertions.AssertAll(); //Common logout = new Common(); //logout.LogOut(); }
public void TC_VerifyNewMemberJourney() { journeyEnabled = cmn.GetConfig("JourneyEnabled").ElementAt(0)[1].ToLower(); if (journeyEnabled.Equals("false")) { Assert.Ignore("Journeys not available for the client"); } //Login Page_Login plogin = new Page_Login(); plogin.Login(); Page_HAPrompt haprompt = new Page_HAPrompt(); haprompt.GoToDashboard(); //Verify Recommendations displayed Page_Dashboard dashbrd = new Page_Dashboard(); Assert.IsTrue(dashbrd.JourneySectionDisplayed(), "Recommendation section missing"); // Navigate to My Journey page Common navigate = new Common(); navigate.GoToMyJourney(); //Verify Recommendations Page_MyJourney journey = new Page_MyJourney(softassertions); List <string[]> journeydata = CSVReaderDataTable.GetCSVData("JourneyContent", pageName, "newmember_journey"); journey.VerifyNewMemberJourney(journeydata); is_soft_assert = true; softassertions.AssertAll(); //Logout Common logout = new Common(); logout.LogOut(); }
public void NavigateToDashboard() { Page_Dashboard dashbrd = new Page_Dashboard(); Assert.IsTrue(dashbrd.AtDashboard(), "Not Navigated to Dashboard"); }