From 7a685ef932dc9a7e64eab3b1244fdda10e740ed8 Mon Sep 17 00:00:00 2001 From: gouravmpk Date: Thu, 18 Jan 2024 02:32:35 +0530 Subject: [PATCH] Try test --- .../wantedSummaries/__tests__/CodingBounty.spec.tsx | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/frontend/app/src/people/widgetViews/summaries/wantedSummaries/__tests__/CodingBounty.spec.tsx b/frontend/app/src/people/widgetViews/summaries/wantedSummaries/__tests__/CodingBounty.spec.tsx index ff921a76f..e0301766c 100644 --- a/frontend/app/src/people/widgetViews/summaries/wantedSummaries/__tests__/CodingBounty.spec.tsx +++ b/frontend/app/src/people/widgetViews/summaries/wantedSummaries/__tests__/CodingBounty.spec.tsx @@ -142,12 +142,7 @@ describe('MobileView component', () => { expect(iCanHelp).toBeInTheDocument(); }); it('displays "Mark as Paid" when bounty is unpaid', async () => { - const modifiedProps = { - ...defaultProps, - paid: false, - }; - - jest.mock('store', () => ({ + jest.mock('store', () => ({ useStores: () => ({ main: { }, @@ -156,11 +151,13 @@ describe('MobileView component', () => { } }) })); - render(); + render(); await waitFor(() => { const markPaidButton = screen.getByText('Mark as Paid'); + const markUnPaidButton = screen.getByText('Mark as Unpaid'); expect(markPaidButton).toBeInTheDocument(); + expect(markUnPaidButton).toBeInTheDocument(); }); }); it('should render the NameTag with correct props', () => {