From db886aed75c10a9a878d41c9bb9c684f8493d36c Mon Sep 17 00:00:00 2001 From: wjames111 Date: Thu, 5 Sep 2024 12:46:07 -0400 Subject: [PATCH] Adds test coverage for Dont Change update type. --- src/components/Tool/FixCommitmentInfo/Contact.test.tsx | 1 + src/components/Tool/FixCommitmentInfo/FixCommitmentInfo.tsx | 4 +--- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/components/Tool/FixCommitmentInfo/Contact.test.tsx b/src/components/Tool/FixCommitmentInfo/Contact.test.tsx index c22bbe33bf..5028996d5a 100644 --- a/src/components/Tool/FixCommitmentInfo/Contact.test.tsx +++ b/src/components/Tool/FixCommitmentInfo/Contact.test.tsx @@ -131,6 +131,7 @@ describe('FixCommitmentContact', () => { const { getByTestId } = render(); userEvent.click(getByTestId('confirmButton')); + await waitFor(() => { expect(getByTestId('statusSelectError')).toHaveTextContent( 'Please select a status', diff --git a/src/components/Tool/FixCommitmentInfo/FixCommitmentInfo.tsx b/src/components/Tool/FixCommitmentInfo/FixCommitmentInfo.tsx index 770571982f..236050cb6c 100644 --- a/src/components/Tool/FixCommitmentInfo/FixCommitmentInfo.tsx +++ b/src/components/Tool/FixCommitmentInfo/FixCommitmentInfo.tsx @@ -273,9 +273,7 @@ const FixCommitmentInfo: React.FC = ({ key={contact.id} donations={contact.donations?.nodes} statusTitle={ - contact.status - ? contactPartnershipStatus[contact.status] - : '' + contactPartnershipStatus[contact.status] || '' } statusValue={ getLocalizedContactStatus(t, contact.status) || ''