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
StateExceptionTest.php
Go to the documentation of this file.
1
<?php
7
namespace
Magento\Framework\Exception\Test\Unit
;
8
9
use \Magento\Framework\Exception\StateException;
10
use
Magento\Framework\Phrase
;
11
15
class
StateExceptionTest
extends
\PHPUnit\Framework\TestCase
16
{
20
public
function
testStateExceptionInstance
()
21
{
22
$instanceClass = \Magento\Framework\Exception\StateException::class;
23
$message
=
'message %1 %2'
;
24
$params
= [
25
'parameter1'
,
26
'parameter2'
,
27
];
28
$cause = new \Exception();
29
$stateException =
new
StateException
(
new
Phrase
(
$message
,
$params
), $cause);
30
$this->assertInstanceOf($instanceClass, $stateException);
31
}
32
}
Magento\Framework\Exception\StateException
Definition:
StateException.php:14
Magento\Framework\Exception\Test\Unit
Definition:
AuthenticationExceptionTest.php:7
$message
$message
Definition:
notifications.php:7
Magento\Framework\Exception\Test\Unit\StateExceptionTest
Definition:
StateExceptionTest.php:15
Magento\Framework\Exception\Test\Unit\StateExceptionTest\testStateExceptionInstance
testStateExceptionInstance()
Definition:
StateExceptionTest.php:20
Magento\Framework\Phrase
Definition:
Phrase.php:17
Magento\Framework\Phrase
$params
$params[\Magento\Store\Model\StoreManager::PARAM_RUN_CODE]
Definition:
website.php:18