test(admin): stabilize service center acceptance fixtures

This commit is contained in:
2026-08-08 20:47:26 +08:00
parent aab8e37175
commit e5c6e03033
3 changed files with 19 additions and 4 deletions
@@ -15,7 +15,11 @@ export async function run(context) {
}
const suffix = context.marker.replace(/\D/g, '').slice(-10)
const customerId = id(context.context?.customerId || '10001')
const oceanResponse = await context.request('GET', `${OCEAN}/${ocean.id}`)
const oceanDetail = context.apiSuccess(MODULE, '读取跨服务链路订舱真实客户归属', oceanResponse, `oceanBookingId=${ocean.id}`, OPTIONS)
const customerId = id(oceanDetail?.oceanBooking?.customerId)
context.assert(MODULE, '跨服务链路订舱客户归属有效', oceanResponse, Boolean(customerId), `customerId=${customerId || 'missing'}`, OPTIONS)
if (!customerId) return
const payload = {
outboundOrderId: null, oceanBookingId: ocean.id, containerBookingId: null, loadingPlanId: null,
warehouseId: id(context.createdResources?.warehouse?.id || context.context?.warehouseId || '193000000000000001'),