static::
assertInstanceOf(SalesChannelContextRestorerOrderCriteriaEvent::
class,
$salesChannelContextRestorerCriteriaEvent);
} private function createOrder(TestDataCollection
$ids): void
{ $customer =
(new CustomerBuilder($ids, '10000'
)) ->
add('guest', true
) ->
add('createdAt',
new \
DateTime('- 25 hours'
))->
build();
$data =
[ 'id' =>
$ids->
create('order'
),
'itemRounding' =>
json_decode(json_encode(new CashRoundingConfig(2, 0.01, true
), \JSON_THROW_ON_ERROR
), true, 512, \JSON_THROW_ON_ERROR
),
'totalRounding' =>
json_decode(json_encode(new CashRoundingConfig(2, 0.01, true
), \JSON_THROW_ON_ERROR
), true, 512, \JSON_THROW_ON_ERROR
),
'orderNumber' => Uuid::
randomHex(),
'billingAddressId' =>
$ids->
create('billing-address'
),
'currencyId' => Defaults::CURRENCY,
'languageId' => Defaults::LANGUAGE_SYSTEM,
'salesChannelId' => TestDefaults::SALES_CHANNEL,
'orderDateTime'
=> (new \
DateTime())->
format(Defaults::STORAGE_DATE_TIME_FORMAT
),
'currencyFactor' => 1,
'stateId' =>
$this->
getStateId('open', 'order.state'
),
'price' =>
new CartPrice(200, 200, 200,
new CalculatedTaxCollection(),
new TaxRuleCollection(), CartPrice::TAX_STATE_GROSS
),
'shippingCosts' =>
new CalculatedPrice(0, 0,
new CalculatedTaxCollection(),
new TaxRuleCollection()),