本文整理汇总了PHP中Magento\Store\Model\System\Store::setIsAdminScopeAllowed方法的典型用法代码示例。如果您正苦于以下问题:PHP Store::setIsAdminScopeAllowed方法的具体用法?PHP Store::setIsAdminScopeAllowed怎么用?PHP Store::setIsAdminScopeAllowed使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Magento\Store\Model\System\Store
的用法示例。
在下文中一共展示了Store::setIsAdminScopeAllowed方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: testGetStoreValuesForForm
/**
* @dataProvider getStoreValuesForFormDataProvider
* @SuppressWarnings(PHPMD.ExcessiveParameterList)
*/
public function testGetStoreValuesForForm($empty, $all, $storeId, $groupId, $websiteId, $storeName, $groupName, $websiteName, $storeGroupId, $groupWebsiteId, $expectedResult)
{
$this->websiteMock->expects($this->any())->method('getId')->willReturn($websiteId);
$this->websiteMock->expects($this->any())->method('getName')->willReturn($websiteName);
$this->groupMock->expects($this->any())->method('getId')->willReturn($groupId);
$this->groupMock->expects($this->any())->method('getName')->willReturn($groupName);
$this->groupMock->expects($this->any())->method('getWebsiteId')->willReturn($groupWebsiteId);
$this->storeMock->expects($this->any())->method('getId')->willReturn($storeId);
$this->storeMock->expects($this->any())->method('getName')->willReturn($storeName);
$this->storeMock->expects($this->any())->method('getGroupId')->willReturn($storeGroupId);
$this->model->setIsAdminScopeAllowed(true);
$this->assertEquals($this->model->getStoreValuesForForm($empty, $all), $expectedResult);
}