This commit is contained in:
2026-10-22 11:56:47 +08:00
parent 5d71af1ac9
commit de96e47d74
71 changed files with 1296 additions and 332 deletions
@@ -45,12 +45,13 @@ test('draft and removal checks use actual IDs plus readback rather than snapshot
assert.ok(source.includes(value), value)
})
test('fulfillment checks PDF signature, platform replay and immutable pallets after transfer', async () => {
test('fulfillment checks PDF signature, automatic documents and immutable stock around loading replay', async () => {
const source = await read('phase5-overseas-fulfillment.mjs')
for (const value of ['requestBinary', '/prints/bol', "=== '%PDF-'", '/transfer-delivery',
'replay.data?.replayed', 'JSON.stringify(replay.data.result) === JSON.stringify(result)',
for (const value of ['requestBinary', '/prints/bol', "=== '%PDF-'", 'await readAutomaticDispatchDelivery(',
'value?.documents?.deliveries', 'value?.documents?.outbounds', 'await verifyAutomaticDeparture(',
'sameSnapshot(proof.stockAfter, proof.stockAfterDepart)', 'sameSnapshot(proof.ledgerAfter, proof.ledgerAfterDepart)'])
assert.ok(source.includes(value), value)
assert.doesNotMatch(source, /\/transfer-delivery|\/delivery-arrangement|\/depart`/)
const helper = await read('fleet-trip-fulfillment.mjs')
for (const value of ['state.itemsBefore', 'JSON.stringify(state.itemsBefore) === JSON.stringify(state.itemsAfter)',
'proof.loadingCommand.replay = replay', 'proof.loadingCommand.platformRejection = await command',