Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
TimestampItemNormalizer example
protected
$item
;
/** * {@inheritdoc} */
protected
function
setUp
(
)
: void
{
parent::
setUp
(
)
;
$this
->normalizer =
new
TimestampItemNormalizer
(
)
;
}
/** * @covers ::supportsNormalization */
public
function
testSupportsNormalization
(
)
{
$timestamp_item
=
$this
->
createTimestampItemProphecy
(
)
;
$this
->
assertTrue
(
$this
->normalizer->
supportsNormalization
(
$timestamp_item
->
reveal
(
)
)
)
;
$entity_ref_item
=
$this
->
prophesize
(
EntityReferenceItem::
class
)
;
$this
->
assertFalse
(
$this
->normalizer->
supportsNormalization
(
$entity_ref_item
->
reveal
(
)
)
)
;
}