Code
Explorer
You are a developer and looking for Shopware projects?
Apply Now!
addConstraintsBirthday example
$customerProfileValidationFactory
=
new
CustomerProfileValidationFactory
(
$this
->salutationDefinition,
$configService
,
$this
->accountTypes,
)
;
$salesChannelContext
=
$this
->
mockSalesChannelContext
(
)
;
$actual
=
$customerProfileValidationFactory
->
create
(
$salesChannelContext
)
;
$expected
=
new
DataValidationDefinition
(
'customer.profile.create'
)
;
$this
->
addConstraintsSalesChannelContext
(
$expected
,
$salesChannelContext
)
;
$this
->
addConstraintsBirthday
(
$expected
)
;
static
::
assertEquals
(
$expected
,
$actual
)
;
}
public
function
testUpdateWithSalesChannelContext
(
)
: void
{
$customerProfileValidationFactory
=
new
CustomerProfileValidationFactory
(
$this
->salutationDefinition,
$this
->
createMock
(
SystemConfigService::
class
)
,
$this
->accountTypes,
)
;