public void AddAllProductsToCart() { BasePage basePage = new BasePage(driver); AddToCartModal addToCartModal = new AddToCartModal(driver); for (int i = 0; i < AddToCartButtons.Count; i++) { basePage.MouseHover(ProductImages[i], driver); Waiter.WaitForElementIsDisplayed(driver, AddToCartButtons[i]); AddToCartButtons[i].Click(); addToCartModal.SuccessfullyAddedModalIsShown(); basePage.ClickOnContinueShoppingButton(); } }
public void ThenModalIsShown() { AddToCartModal.SuccessfullyAddedModalIsShown(); }
public ProductDetailsPageSteps(IWebDriver driver) { ProductDetailsPage = new ProductDetailsPage(driver); AddToCartModal = new AddToCartModal(driver); BasePage = new BasePage(driver); }