public void AddProductToCart() { productListPage.AddToCartFirstProduct(shoppingCartBO); String expectedResult = "Success: You have added " + shoppingCartBO.ProductName + " to your shopping cart!\r\n×"; Assert.AreEqual(expectedResult, productListPage.SuccessfullyAddedText); }
public void TestInitialize() { options = new ChromeOptions(); options.AddArgument("--ignore-ssl-errors=yes"); options.AddArgument("--ignore-certificate-errors"); driver = new ChromeDriver(options); driver.Manage().Window.Maximize(); driver.Navigate().GoToUrl("http://opencart.abstracta.us/"); menuItem = new MenuItemControl(driver); homePage = new HomePage(driver); productListPage = homePage.NavigateToTabletsProductList(driver); productListPage.AddToCartFirstProduct(shoppingCartBO); shoppingCartPage = menuItem.NavigateToShoppingCart(driver); }