9 use Magento\Catalog\Test\Page\Product\CatalogProductView;
10 use Magento\Mtf\Client\BrowserInterface;
11 use Magento\Mtf\Constraint\AbstractConstraint;
12 use Magento\Mtf\Fixture\FixtureInterface;
13 use Magento\Cms\Test\Page\CmsIndex;
32 CatalogProductView $catalogProductView,
34 BrowserInterface $browser,
35 FixtureInterface $initialProduct,
39 $browser->open($_ENV[
'app_frontend_url'] . $initialProduct->getUrlKey() .
'.html');
41 $cmsIndex->getStoreSwitcherBlock()->selectStoreView(
$store->getName());
42 $cmsIndex->getLinksBlock()->waitWelcomeMessage();
43 \PHPUnit\Framework\Assert::assertEquals(
44 $productNames[
$store->getStoreId()],
45 $catalogProductView->getViewBlock()->getProductName(),
46 sprintf(
'Wrong product name is displayed for %s store view.',
$store->getName())
58 return 'Product name is correct on the storefront';
processAssert(CatalogProductView $catalogProductView, CmsIndex $cmsIndex, BrowserInterface $browser, FixtureInterface $initialProduct, array $stores, array $productNames)