Example #1
0
        public void CreateARO_TG_US()
        {
            Driver.WebDriver.Navigate().GoToUrl(Driver.GetUrl("TowerGardenStore", "US"));
            MainPage.NavigateBuyPage();
            BuyPage.AddToCart("GT360");
            Header.NavigateCartPage();
            CartPage.ZipLookup("38017");
            CartPage.CitySelect("0.COLLIERVILLE");
            CartPage.Next();
            CheckoutPage.InputShippingAndBillingInfo("Test", "Tester", "9018503000", "*****@*****.**", "140 Crescent DR", "38017", "0.COLLIERVILLE", "TENNESSEE", "US", true, "WebAd");
            CheckoutPage.InputPaymentMethod("Visa", "4242424242424242", "02", "2022", "189");

            CheckoutPage.CompletePurchase();
            new WebDriverWait(Driver.WebDriver, TimeSpan.FromSeconds(30)).Until(ExpectedConditions.ElementIsVisible(By.CssSelector("div[class='jp-acct-block1']")));
            Assert.IsTrue(Driver.WebDriver.PageSource.Contains("Your order has been placed. You should receive a confirmation email shortly.") || Driver.WebDriver.PageSource.Contains("You will receive an additional e-mail when your order is shipped."));
            Thread.Sleep(5000);
        }