public void Buy(int amountToBuy)
        {
            DressesPage dressesPage = new DressesPage();

            dressesPage.AddToCart();

            ShoppingCartSummaryPage shoppingCartSummaryPage = dressesPage.ProceedToCheckOut();

            shoppingCartSummaryPage.AddQty(amountToBuy);
            TotalOrder = shoppingCartSummaryPage.GetTotal();

            ShoppingCartAddressPage shoppingCartAddressPage = shoppingCartSummaryPage.ProceedToCheckOut();

            ShoppingCartShippingPage shoppingCartShippingPage = shoppingCartAddressPage.ProceedToCheckOut();

            shoppingCartShippingPage.AcceptTerms();

            ShoppingCartPaymentPage shoppingCartPaymentPage = shoppingCartShippingPage.ProceedToCheckOut();
            Confirm confirm = shoppingCartPaymentPage.PayByBank();

            Order orderToBuy = confirm.ConfirmOrderToBuy();

            TotalPaid = orderToBuy.GetAmount();
        }
Ejemplo n.º 2
0
 public void ThenIAddProductsToCart()
 {
     myAccountPage.ClickDresses();
     dressesPage.AddToCart();
     dressesPage.ProceedToCheckOut();
 }