diff --git a/src/QuickMarcEditor/QuickMarcEditWrapper.test.js b/src/QuickMarcEditor/QuickMarcEditWrapper.test.js index e6103f67..7b816cea 100644 --- a/src/QuickMarcEditor/QuickMarcEditWrapper.test.js +++ b/src/QuickMarcEditor/QuickMarcEditWrapper.test.js @@ -490,6 +490,7 @@ describe('Given QuickMarcEditWrapper', () => { await act(async () => { fireEvent.click(getByText('ui-quick-marc.record.save.continue')); }); const fieldIds = mockRecords[MARC_TYPES.BIB].slice(1).map(field => field.id); + expect(mockRefreshPageData).toHaveBeenCalledWith(fieldIds); }); }); diff --git a/src/QuickMarcEditor/QuickMarcEditorContainer.js b/src/QuickMarcEditor/QuickMarcEditorContainer.js index af2288c4..09bc755a 100644 --- a/src/QuickMarcEditor/QuickMarcEditorContainer.js +++ b/src/QuickMarcEditor/QuickMarcEditorContainer.js @@ -172,7 +172,12 @@ const QuickMarcEditorContainer = ({ if (action === QUICK_MARC_ACTIONS.CREATE) { dehydratedMarcRecord = createRecordDefaults[marcType](instanceResponse, fixedFieldSpecResponse); } else { - dehydratedMarcRecord = dehydrateMarcRecordResponse(marcRecordResponse, marcType, fixedFieldSpecResponse, fieldIds); + dehydratedMarcRecord = dehydrateMarcRecordResponse( + marcRecordResponse, + marcType, + fixedFieldSpecResponse, + fieldIds, + ); } const formattedMarcRecord = formatMarcRecordByQuickMarcAction(dehydratedMarcRecord, action, marcType); diff --git a/src/QuickMarcEditor/utils.test.js b/src/QuickMarcEditor/utils.test.js index 38536faa..b4082e71 100644 --- a/src/QuickMarcEditor/utils.test.js +++ b/src/QuickMarcEditor/utils.test.js @@ -154,7 +154,12 @@ describe('QuickMarcEditor utils', () => { const fieldIds = ['id-1', 'id-2']; - const dehydratedMarcRecord = utils.dehydrateMarcRecordResponse(marcRecord, MARC_TYPES.BIB, fixedFieldSpecBib, fieldIds); + const dehydratedMarcRecord = utils.dehydrateMarcRecordResponse( + marcRecord, + MARC_TYPES.BIB, + fixedFieldSpecBib, + fieldIds, + ); const field001 = dehydratedMarcRecord.records[1]; const field006 = dehydratedMarcRecord.records[2]; const field007 = dehydratedMarcRecord.records[3];