public void WhenISetDates_(string startDate, string endDate)
 {
     //Thread.Sleep(200);
     driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(10);
     CustomMethods.clickOnDate(driver, CustomMethods.ChangeFormat(startDate));
     CustomMethods.clickOnDate(driver, CustomMethods.ChangeFormat(endDate));
 }
示例#2
0
 public void GivenIAmInSignUpPage()
 {
     CustomMethods.GoToURL(driver, "https://booking.com");
     mainPage.ChooseDefaultSettings();
     driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(10);
     Assert.AreEqual("Booking.com | Official site | The best hotels & accommodations", driver.Title);
     mainPage.GotToRegisterPage();
 }
示例#3
0
 public void WhenMainPageIsOpened()
 {
     Console.WriteLine("Main Page is Opened");
     CustomMethods.AcceptCookie(driver);
     //Here I'm cheating, because time to time there are random banners for the new registered clients,
     //I'm just refreshing the page 2 times to skip them :(
     for (int i = 0; i < 2; i++)
     {
         driver.Navigate().Refresh();
     }
 }
        public void GivenIHaveAccountCreated()
        {
            CustomMethods.GoToURL(driver, "https://booking.com");
            //driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(10);
            //Thread.Sleep(2000);
            mainPage.ChooseDefaultSettings();
            mainPage.GoToSignInPage();

            signInPage.TypeCredentials();
            driver.Manage().Timeouts().ImplicitWait = TimeSpan.FromSeconds(10);
            //Thread.Sleep(5000);
            CustomMethods.AcceptCookie(driver);
        }