From 0c01844eb66b59aaff1d838b483a5525624dc18a Mon Sep 17 00:00:00 2001 From: pakxe Date: Fri, 16 Aug 2024 03:40:26 +0900 Subject: [PATCH] =?UTF-8?q?chore:=20toEqual=20->=20toStrictEqual=EB=A1=9C?= =?UTF-8?q?=20=EB=B3=80=EA=B2=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../useSearchMemberReportList.test.tsx | 2 +- client/src/hooks/useStepList/useStepList.test.tsx | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/client/src/hooks/useSearchMemberReportList/useSearchMemberReportList.test.tsx b/client/src/hooks/useSearchMemberReportList/useSearchMemberReportList.test.tsx index 4b656eaf5..2688a9a04 100644 --- a/client/src/hooks/useSearchMemberReportList/useSearchMemberReportList.test.tsx +++ b/client/src/hooks/useSearchMemberReportList/useSearchMemberReportList.test.tsx @@ -19,7 +19,7 @@ describe('useSearchMemberReportList', () => { it('빈 값을 검색한다면 검색 목록은 비어있다.', async () => { const {result} = initializeProvider(''); - await waitFor(() => expect(result.current.memberReportSearchList).toEqual(reportListJson)); + await waitFor(() => expect(result.current.memberReportSearchList).toStrictEqual(reportListJson)); }); it('검색어의 일부와 일치하는 이름이 있다면 해당 이름을 목록에 반환한다.', async () => { diff --git a/client/src/hooks/useStepList/useStepList.test.tsx b/client/src/hooks/useStepList/useStepList.test.tsx index 207c821d1..81963b73a 100644 --- a/client/src/hooks/useStepList/useStepList.test.tsx +++ b/client/src/hooks/useStepList/useStepList.test.tsx @@ -38,14 +38,14 @@ describe('useStepList', () => { it('처음 호출하면 stepList 값을 요청해 받아온다.', async () => { const {result} = initializeProvider(); - await waitFor(() => expect(result.current.stepListResult.stepList).toEqual(stepListMockData)); + await waitFor(() => expect(result.current.stepListResult.stepList).toStrictEqual(stepListMockData)); }); it('처음 호출하면 모든 멤버의 목록을 요청해 받아온다.', async () => { const {result} = initializeProvider(); const allMemberList = getMemberNameList(); - await waitFor(() => expect(result.current.stepListResult.allMemberList).toEqual(allMemberList)); + await waitFor(() => expect(result.current.stepListResult.allMemberList).toStrictEqual(allMemberList)); }); it('지출 내역의 총액을 계산한다.', async () => { @@ -58,9 +58,9 @@ describe('useStepList', () => { }, 0); // 값이 세팅되기까지 대기하기 위함. 그래서 아래 한 줄 없으면 에러남 - await waitFor(() => expect(result.current.stepListResult.stepList).toEqual(stepListMockData)); + await waitFor(() => expect(result.current.stepListResult.stepList).toStrictEqual(stepListMockData)); - expect(result.current.stepListResult.getTotalPrice()).toEqual(totalPrice); + expect(result.current.stepListResult.getTotalPrice()).toStrictEqual(totalPrice); }); it('들어옴 멤버를 추가한다.', async () => { @@ -100,7 +100,7 @@ describe('useStepList', () => { await act(async () => result.current.stepListResult.addBill(billList, () => {})); - expect(result.current.stepListResult.stepList).toEqual(updatedStepList); + expect(result.current.stepListResult.stepList).toStrictEqual(updatedStepList); }); it('provider안에서 호출되지 않으면 에러를 던진다.', () => {