Skip to content

Commit

Permalink
test: add test case (#1037)
Browse files Browse the repository at this point in the history
  • Loading branch information
zombieJ authored Nov 14, 2023
1 parent 0a4e767 commit a54e44b
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions tests/Virtual.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -396,4 +396,20 @@ describe('Table.Virtual', () => {
});
});
});

it('components', async () => {
const { container } = getTable({
components: {
header: {
cell: function MyTh(props: any) {
return <th {...props} data-mark="my-th" />;
},
},
},
});

await waitFakeTimer();

expect(container.querySelector('thead th')).toHaveAttribute('data-mark', 'my-th');
});
});

1 comment on commit a54e44b

@vercel
Copy link

@vercel vercel bot commented on a54e44b Nov 14, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

table – ./

table-react-component.vercel.app
table-git-master-react-component.vercel.app

Please sign in to comment.