From a0c7ae37ad899683d45e644f92a15cb486c25abe Mon Sep 17 00:00:00 2001 From: pfdgithub Date: Wed, 18 May 2022 14:15:28 +0800 Subject: [PATCH] fix: test cases --- tests/Select.test.tsx | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/tests/Select.test.tsx b/tests/Select.test.tsx index 693bcb78f..31717a2f5 100644 --- a/tests/Select.test.tsx +++ b/tests/Select.test.tsx @@ -1857,12 +1857,29 @@ describe('Select.Basic', () => { const onLabelRender = jest.fn(); const labelRender = (props: any) => { const { label, value } = props; + console.log(props); onLabelRender(); return `${label}-${value}`; }; + const wrapper = mount( + ); expect(onLabelRender).toHaveBeenCalled(); - expect(findSelection(wrapper).text()).toEqual('a-a'); + expect(findSelection(wrapper).text()).toEqual('fakeLabel-a'); }); });