diff --git a/src/modules/container-loading/api/platformContainerCustoms.test.ts b/src/modules/container-loading/api/platformContainerCustoms.test.ts index 5f2b760b..199831eb 100644 --- a/src/modules/container-loading/api/platformContainerCustoms.test.ts +++ b/src/modules/container-loading/api/platformContainerCustoms.test.ts @@ -16,6 +16,8 @@ describe('platform container customs API', () => { it('uses the frozen customs-v1 paths and preserves long ids as strings', async () => { const get = vi.spyOn(http, 'get').mockResolvedValue({ code: '200', message: 'ok', data: customs }) const result = await getContainerCustoms('2092438843630391402') + expect(result).not.toBeNull() + if (!result) throw new Error('expected completed loading plan customs view') expect(get).toHaveBeenCalledWith('/platform/v1/customs/loading-plans/2092438843630391402') expect(result).toMatchObject({ aggregateId: '2092438843630391401', loadingPlanId: '2092438843630391402', containerBookingId: '2092438843630391403' }) expect(result.inbounds[0]).toMatchObject({ inboundId: '2092438843630391404', orderId: '2092438843630391405', tenantId: '2092438843630391406' })