/** * @magentoDataFixture Magento/Catalog/_files/multiple_products.php * @magentoAppIsolation enabled * @magentoAppArea frontend */ public function testPrepareAndRender() { $this->_helper->prepareAndRender(10, $this->_controller); $this->assertNotEmpty($this->_controller->getResponse()->getBody()); $this->assertEquals(10, $this->objectManager->get('Magento\\Catalog\\Model\\Session')->getLastViewedProductId()); }