Ejemplo n.º 1
0
        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_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();
        }
Ejemplo n.º 4
0
        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();
        }
Ejemplo n.º 5
0
        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_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 NavigateToDashboard()
        {
            Page_Dashboard dashbrd = new Page_Dashboard();

            Assert.IsTrue(dashbrd.AtDashboard(), "Not Navigated to Dashboard");
        }