mirror of
https://github.com/shlinkio/shlink-web-client.git
synced 2026-03-14 11:33:51 +00:00
Replace all remaining bootstrap utility classes with tailwind classes
This commit is contained in:
@@ -10,30 +10,18 @@ describe('<ServersListGroup />', () => {
|
||||
fromPartial({ name: 'foo', id: '123' }),
|
||||
fromPartial({ name: 'bar', id: '456' }),
|
||||
];
|
||||
const setUp = (params: { servers?: ServerWithId[]; withChildren?: boolean; borderless?: boolean } = {}) => {
|
||||
const { servers = [], withChildren = true, borderless } = params;
|
||||
const setUp = (params: { servers?: ServerWithId[]; borderless?: boolean } = {}) => {
|
||||
const { servers = [], borderless } = params;
|
||||
|
||||
return render(
|
||||
<MemoryRouter>
|
||||
<ServersListGroup servers={servers} borderless={borderless}>
|
||||
{withChildren ? 'The list of servers' : undefined}
|
||||
</ServersListGroup>
|
||||
<ServersListGroup servers={servers} borderless={borderless} />
|
||||
</MemoryRouter>,
|
||||
);
|
||||
};
|
||||
|
||||
it('passes a11y checks', () => checkAccessibility(setUp()));
|
||||
|
||||
it('renders title', () => {
|
||||
setUp({});
|
||||
expect(screen.getByTestId('title')).toHaveTextContent('The list of servers');
|
||||
});
|
||||
|
||||
it('does not render title when children is not provided', () => {
|
||||
setUp({ withChildren: false });
|
||||
expect(screen.queryByTestId('title')).not.toBeInTheDocument();
|
||||
});
|
||||
|
||||
it.each([
|
||||
[servers],
|
||||
[[]],
|
||||
|
||||
Reference in New Issue
Block a user