10 use Magento\Catalog\Test\Page\Product\CatalogProductView;
11 use Magento\Checkout\Test\Page\CheckoutCart;
12 use Magento\Checkout\Test\Page\CheckoutOnepage;
14 use Magento\Mtf\Client\BrowserInterface;
15 use Magento\Mtf\TestCase\Injectable;
51 CatalogProductView $catalogProductView,
52 BrowserInterface $browser,
53 CheckoutOnepage $checkoutOnepage,
60 $cartPage->getCartBlock()->clearShoppingCart();
63 $browser->open($_ENV[
'app_frontend_url'] .
$product->getUrlKey() .
'.html');
64 $productView = $catalogProductView->getViewBlock();
66 $productView->setQty(
$product->getCheckoutData()[
'qty']);
67 $productView->clickAddToCart();
68 $catalogProductView->getMessagesBlock()->waitSuccessMessage();
70 $checkoutOnepage->open();
71 $checkoutOnepage->getShippingBlock()->fill(
$customer);
72 $checkoutOnepage->getShippingMethodBlock()->clickContinue();
test(CatalogProductSimple $product, CheckoutCart $cartPage, CatalogProductView $catalogProductView, BrowserInterface $browser, CheckoutOnepage $checkoutOnepage, Customer $customer)