test(fba): retain parent proof across isolated fragment contexts
This commit is contained in:
@@ -449,7 +449,8 @@ async function sendFragment(context, producer, picker, merchantToken, index) {
|
||||
export async function withDeliveryEventRecovery(context, faultScope, warehouseId, index, sign) {
|
||||
const executor = context.context.f40DeliveryEventFaultExecutor
|
||||
if (!executor || index !== 0) return sign()
|
||||
const proof = context.createdResources.phase5RootFulfillment
|
||||
const proof = context.context.f40RootFulfillmentProof
|
||||
if (!proof) throw Error('F40 parent fulfillment proof required')
|
||||
if (proof.deliveryEventRecovery) throw Error('F40 delivery recovery already attempted')
|
||||
const reader = context.context.f40ReadOnlyInventoryEvidence
|
||||
if (typeof reader !== 'function') throw Error('F40 complete inventory evidence reader required')
|
||||
@@ -521,6 +522,7 @@ async function runRootFulfillment(context) {
|
||||
const scope = Object.create(context)
|
||||
scope.marker = `${context.marker}-F40`
|
||||
scope.context = { ...context.context, orderDestinationType: 'FBA', orderFulfillmentType: 'STANDARD',
|
||||
f40RootFulfillmentProof: proof,
|
||||
orderStopAtApproved:cancelRemainder,
|
||||
orderProfile: { taxMode, fulfillmentType: 'STANDARD' },f40TaxMode:taxMode,f40TaxEvidence:proof.taxCustoms,
|
||||
waitSplitVariant: { skuCount: 1, packageCountPerSku: 2, packageCounts: [2] },
|
||||
|
||||
Reference in New Issue
Block a user