public void VerifyFacebookLogin2()
        {
            try
            {
                InitalizeDriver("Chrome");
                NavigateToFaceBook();

                string title = driver.Title;
                Thread.Sleep(2000);


                Facebook fb = new Facebook(driver);
                fb.FaceBookLogin("UserName", "Password");
                Thread.Sleep(1000);

                Assert.AreEqual("Facebook - Log Innn  or Sign Up", title);
            }

            catch (Exception exception)
            {
                Logger.Error(exception.StackTrace);
                ((ITakesScreenshot)driver).GetScreenshot().SaveAsFile("Test.png", ScreenshotImageFormat.Png);
                throw;
            }
        }
        public void VerifyFacebookLogin()
        {
            InitalizeDriver("Chrome");
            NavigateToFaceBook();

            string title = Rannddoom.gettitlle(driver);

            Thread.Sleep(2000);


            Facebook fb = new Facebook(driver);

            fb.FaceBookLogin("UserName", "Password");
            Thread.Sleep(1000);

            Assert.AreEqual("Facebook - Log In or Sign Up", title);
        }
        public void FacebookLoginTestWIthExcelFIle()
        {
            InitalizeDriver("Chrome");
            NavigateToFaceBook();

            Thread.Sleep(4000);
            Facebook    FBook    = new Facebook(driver);
            ExcelReader Exr      = new ExcelReader();
            string      xlPath   = @"C:\Users\RUSHIT  PATEL\Downloads\FacebookTest.xlsx";
            string      username = Exr.TestReadExcel(xlPath, "Sheet1", 0, 0).ToString();
            string      password = Exr.TestReadExcel(xlPath, "Sheet1", 0, 1).ToString();

            Thread.Sleep(5000);
            FBook.FaceBookLogin(username, password);
            Thread.Sleep(3000);

            IAlert alert = driver.SwitchTo().Alert();
            String text  = alert.Text;



            Thread.Sleep(3000);
            Assert.AreEqual("The password you’ve entered is incorrect.", text);
        }