Skip to content

Commit

Permalink
test: add test case
Browse files Browse the repository at this point in the history
  • Loading branch information
zombieJ committed Nov 14, 2023
1 parent 0a4e767 commit 12c2d22
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');
});
});

0 comments on commit 12c2d22

Please sign in to comment.