Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
getCmsFormElement example
$formCmsElementResolver
=
$this
->
getContainer
(
)
->
get
(
FormCmsElementResolver::
class
)
;
static
::
assertEquals
(
'form',
$formCmsElementResolver
->
getType
(
)
)
;
}
public
function
testResolverUsesAbstractSalutationsRouteToEnrichSlot
(
)
: void
{
$salutationCollection
=
$this
->
getSalutationCollection
(
)
;
$formCmsElementResolver
=
new
FormCmsElementResolver
(
$this
->
getSalutationRoute
(
$salutationCollection
)
)
;
$formElement
=
$this
->
getCmsFormElement
(
)
;
$formCmsElementResolver
->
enrich
(
$formElement
,
new
ResolverContext
(
$this
->
createMock
(
SalesChannelContext::
class
)
,
new
Request
(
)
)
,
new
ElementDataCollection
(
)
)
;
static
::
assertSame
(
$formElement
->
getData
(
)
,
$salutationCollection
)
;
}
public
function
testResolverSortsSalutationsBySalutationKeyDesc
(
)
: void
{