fix(orders): display unknown pooled freight facts without defaults
This commit is contained in:
@@ -107,4 +107,12 @@ describe('platform overseas business API adapter', () => {
|
||||
expect(overseas.post).not.toHaveBeenCalled()
|
||||
expect(overseas.put).not.toHaveBeenCalled()
|
||||
})
|
||||
|
||||
it('preserves unknown pool pallet service and container type in list and detail responses', async () => {
|
||||
const summary = { ...looseboardSummary, palletRequired: null, containerType: null }
|
||||
overseas.get.mockResolvedValueOnce(envelope({ records: [summary], total: 1, page: 1, size: 20, pages: 1 })).mockResolvedValueOnce(envelope({ summary, histories: [] }))
|
||||
expect((await listLocalLooseboardOrders({})).records[0]).toMatchObject({ palletRequired: null, containerType: null })
|
||||
expect(await getLocalLooseboardOrder('LB-1', '10003')).toMatchObject({ palletRequired: null, containerType: null })
|
||||
expect(overseas.get).toHaveBeenCalledTimes(2)
|
||||
})
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user