File tree Expand file tree Collapse file tree 2 files changed +6
-3
lines changed
app/code/Magento/Ui/Controller/Adminhtml/Index/Render
dev/tests/integration/testsuite/Magento/Ui/Controller/Adminhtml/Index/Renderer Expand file tree Collapse file tree 2 files changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -55,7 +55,7 @@ public function execute()
55
55
$ context = $ this ->contextFactory ->create (
56
56
[
57
57
'namespace ' => $ namespace ,
58
- 'pageLayout ' => $ layout
58
+ 'pageLayout ' => $ layout,
59
59
]
60
60
);
61
61
@@ -79,14 +79,15 @@ public function execute()
79
79
* @param mixed $dataProviderConfigData
80
80
* @return bool
81
81
*/
82
- private function validateAclResource ($ dataProviderConfigData )
82
+ private function validateAclResource ($ dataProviderConfigData ): bool
83
83
{
84
84
if (isset ($ dataProviderConfigData ['aclResource ' ])
85
85
&& !$ this ->_authorization ->isAllowed ($ dataProviderConfigData ['aclResource ' ])
86
86
) {
87
87
if (!$ this ->_request ->isAjax ()) {
88
88
$ this ->_redirect ('admin/denied ' );
89
89
}
90
+
90
91
return false ;
91
92
}
92
93
Original file line number Diff line number Diff line change 11
11
use Magento \Framework \AuthorizationInterface ;
12
12
13
13
/**
14
+ * Test for \Magento\Ui\Controller\Adminhtml\Index\Render\Handle.
15
+ *
14
16
* @magentoAppArea adminhtml
15
17
*/
16
18
class HandleTest extends \Magento \TestFramework \TestCase \AbstractBackendController
@@ -23,7 +25,7 @@ public function testExecuteWhenUserDoesNotHavePermission()
23
25
Bootstrap::getObjectManager ()->configure ([
24
26
'preferences ' => [
25
27
AuthorizationInterface::class => \Magento \Ui \Model \AuthorizationMock::class,
26
- ]
28
+ ],
27
29
]);
28
30
$ this ->getRequest ()->setParam ('handle ' , 'customer_index_index ' );
29
31
$ this ->getRequest ()->setParam ('namespace ' , 'customer_listing ' );
You can’t perform that action at this time.
0 commit comments