Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
framework
Exception
Test
Unit
AuthorizationExceptionTest.php
Go to the documentation of this file.
1
<?php
7
namespace
Magento\Framework\Exception\Test\Unit
;
8
9
use \Magento\Framework\Exception\AuthorizationException;
10
use
Magento\Framework\Phrase
;
11
12
class
AuthorizationExceptionTest
extends
\PHPUnit\Framework\TestCase
13
{
17
public
function
testConstructor
()
18
{
19
$authorizationException =
new
AuthorizationException
(
20
new
Phrase
(
21
'The consumer isn\'t authorized to access %resources.'
,
22
[
'consumer_id'
=> 1,
'resources'
=>
'record2'
]
23
)
24
);
25
$this->assertSame(
"The consumer isn't authorized to access record2."
, $authorizationException->getMessage());
26
}
27
}
Magento\Framework\Exception\AuthorizationException
Definition:
AuthorizationException.php:15
Magento\Framework\Exception\Test\Unit\AuthorizationExceptionTest\testConstructor
testConstructor()
Definition:
AuthorizationExceptionTest.php:17
Magento\Framework\Exception\Test\Unit
Definition:
AuthenticationExceptionTest.php:7
Magento\Framework\Exception\Test\Unit\AuthorizationExceptionTest
Definition:
AuthorizationExceptionTest.php:12
Magento\Framework\Phrase
Definition:
Phrase.php:17
Magento\Framework\Phrase