本文整理匯總了PHP中Magento\Backend\Test\Page\Adminhtml\StoreIndex類的典型用法代碼示例。如果您正苦於以下問題:PHP StoreIndex類的具體用法?PHP StoreIndex怎麽用?PHP StoreIndex使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。
在下文中一共展示了StoreIndex類的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: processAssert
/**
* Assert that displayed Store Group data on edit page equals passed from fixture
*
* @param StoreIndex $storeIndex
* @param EditGroup $editGroup
* @param StoreGroup $storeGroup
* @param StoreGroup $storeGroupOrigin [optional]
* @return void
*/
public function processAssert(StoreIndex $storeIndex, EditGroup $editGroup, StoreGroup $storeGroup, StoreGroup $storeGroupOrigin = null)
{
$fixtureData = $storeGroupOrigin != null ? array_merge($storeGroupOrigin->getData(), $storeGroup->getData()) : $storeGroup->getData();
$storeIndex->open()->getStoreGrid()->searchAndOpenStoreGroup($storeGroup);
$formData = $editGroup->getEditFormGroup()->getData();
$errors = $this->verifyData($fixtureData, $formData);
\PHPUnit_Framework_Assert::assertEmpty($errors, $errors);
}
示例2: processAssert
/**
* Assert that displayed Website data on edit page equals passed from fixture
*
* @param StoreIndex $storeIndex
* @param EditWebsite $editWebsite
* @param Website $website
* @return void
*/
public function processAssert(StoreIndex $storeIndex, EditWebsite $editWebsite, Website $website)
{
$fixtureData = $website->getData();
$storeIndex->open()->getStoreGrid()->searchAndOpenWebsite($website);
$formData = $editWebsite->getEditFormWebsite()->getData();
$errors = $this->verifyData($fixtureData, $formData);
\PHPUnit_Framework_Assert::assertEmpty($errors, $errors);
}
示例3: processAssert
/**
* Assert that displayed Store View data on edit page equals passed from fixture
*
* @param StoreIndex $storeIndex
* @param StoreNew $storeNew
* @param Store $store
* @return void
*/
public function processAssert(StoreIndex $storeIndex, StoreNew $storeNew, Store $store)
{
$storeIndex->open()->getStoreGrid()->searchAndOpenStore($store);
$formData = $storeNew->getStoreForm()->getData();
$fixtureData = $store->getData();
$errors = $this->verifyData($fixtureData, $formData);
\PHPUnit_Framework_Assert::assertEmpty($errors, $errors);
}
示例4: processAssert
/**
* Assert that success messages is displayed after deleting website
*
* @param StoreIndex $storeIndex
* @return void
*/
public function processAssert(StoreIndex $storeIndex)
{
$actualMessages = $storeIndex->getMessagesBlock()->getSuccessMessages();
\PHPUnit_Framework_Assert::assertTrue(in_array(self::SUCCESS_BACKUP_MESSAGE, $actualMessages) && in_array(self::SUCCESS_DELETE_MESSAGE, $actualMessages), 'Wrong success messages are displayed.');
}
示例5: processAssert
/**
* Assert that success message is displayed after Store View has been created
*
* @param StoreIndex $storeIndex
* @return void
*/
public function processAssert(StoreIndex $storeIndex)
{
\PHPUnit_Framework_Assert::assertEquals(self::SUCCESS_MESSAGE, $storeIndex->getMessagesBlock()->getSuccessMessages(), 'Wrong success message is displayed.');
}
示例6: processAssert
/**
* Assert that created Store Group can not be found in Stores grid by name
*
* @param StoreIndex $storeIndex
* @param StoreGroup $storeGroup
* @return void
*/
public function processAssert(StoreIndex $storeIndex, StoreGroup $storeGroup)
{
$storeGroupName = $storeGroup->getName();
$storeIndex->open()->getStoreGrid()->search(['group_title' => $storeGroupName]);
\PHPUnit_Framework_Assert::assertFalse($storeIndex->getStoreGrid()->isStoreExists($storeGroupName), 'Store group \'' . $storeGroupName . '\' is present in grid.');
}
示例7: processAssert
/**
* Assert that created Website can't be found in grid by name
*
* @param StoreIndex $storeIndex
* @param Website $website
* @return void
*/
public function processAssert(StoreIndex $storeIndex, Website $website)
{
$websiteName = $website->getName();
$storeIndex->open()->getStoreGrid()->search(['website_title' => $websiteName]);
\PHPUnit_Framework_Assert::assertFalse($storeIndex->getStoreGrid()->isWebsiteExists($website), 'Website \'' . $websiteName . '\' is present in grid.');
}
示例8: processAssert
/**
* Assert that created Store View can be found in Stores grid by name
*
* @param StoreIndex $storeIndex
* @param Store $store
* @return void
*/
public function processAssert(StoreIndex $storeIndex, Store $store)
{
$storeName = $store->getName();
$storeIndex->open()->getStoreGrid()->search(['store_title' => $storeName]);
\PHPUnit_Framework_Assert::assertTrue($storeIndex->getStoreGrid()->isStoreExists($storeName), 'Store \'' . $storeName . '\' is not present in grid.');
}
示例9: processAssert
/**
* Assert that Website visible on Store Group Form in Website dropdown
*
* @param StoreIndex $storeIndex
* @param NewGroupIndex $newGroupIndex
* @param Website $website
* @return void
*/
public function processAssert(StoreIndex $storeIndex, NewGroupIndex $newGroupIndex, Website $website)
{
$websiteName = $website->getName();
$storeIndex->open()->getGridPageActions()->createStoreGroup();
\PHPUnit_Framework_Assert::assertTrue($newGroupIndex->getEditFormGroup()->isWebsiteVisible($websiteName), 'Website \'' . $websiteName . '\' is not present on Store Group Form in Website dropdown.');
}
示例10: processAssert
/**
* Assert that New Store Group visible on StoreView Form in Store dropdown
*
* @param StoreIndex $storeIndex
* @param StoreNew $storeNew
* @param StoreGroup $storeGroup
* @return void
*/
public function processAssert(StoreIndex $storeIndex, StoreNew $storeNew, StoreGroup $storeGroup)
{
$storeGroupName = $storeGroup->getName();
$storeIndex->open()->getGridPageActions()->addStoreView();
\PHPUnit_Framework_Assert::assertTrue($storeNew->getStoreForm()->isStoreVisible($storeGroupName), 'Store Group \'' . $storeGroupName . '\' is not present on StoreView Form in Store dropdown.');
}
示例11: test
/**
* Runs Test Creation for StoreEntityTest
*
* @param Store $store
* @return void
*/
public function test(Store $store)
{
//Steps:
$this->storeIndex->open();
$this->storeIndex->getGridPageActions()->addStoreView();
$this->storeNew->getStoreForm()->fill($store);
$this->storeNew->getFormPageActions()->save();
}
示例12: test
/**
* Create New StoreGroup
*
* @param StoreGroup $storeGroup
* @return void
*/
public function test(StoreGroup $storeGroup)
{
//Steps
$this->storeIndex->open();
$this->storeIndex->getGridPageActions()->createStoreGroup();
$this->newGroupIndex->getEditFormGroup()->fill($storeGroup);
$this->newGroupIndex->getFormPageActions()->save();
}
示例13: test
/**
* Create Website
*
* @param Website $website
* @return void
*/
public function test(Website $website)
{
//Steps
$this->storeIndex->open();
$this->storeIndex->getGridPageActions()->addNew();
$this->newWebsiteIndex->getEditWebsiteForm()->fill($website);
$this->newWebsiteIndex->getFormPageActions()->save();
}
示例14: test
/**
* Runs Test Creation for StoreEntityTest
*
* @param Store $store
* @return void
*/
public function test(Store $store)
{
$this->markTestIncomplete('MAGETWO-48723');
//Steps:
$this->storeIndex->open();
$this->storeIndex->getGridPageActions()->addStoreView();
$this->storeNew->getStoreForm()->fill($store);
$this->storeNew->getFormPageActions()->save();
}
示例15: test
/**
* Runs Update Store Entity test
*
* @param Store $storeInitial
* @param Store $store
* @return void
*/
public function test(Store $storeInitial, Store $store)
{
// Preconditions:
$storeInitial->persist();
// Steps:
$this->storeIndex->open();
$this->storeIndex->getStoreGrid()->searchAndOpenStore($storeInitial);
$this->editStore->getStoreForm()->fill($store);
$this->editStore->getFormPageActions()->save();
}