Skip to content

Commit a03318f

Browse files
committed
fix asynchrone issue in tests
1 parent 835fd62 commit a03318f

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/ra-ui-materialui/src/list/SimpleList/SimpleList.spec.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,8 @@ describe('<SimpleList />', () => {
262262

263263
it('should be customized by a theme', async () => {
264264
render(<Themed />);
265-
expect(screen.queryByTestId('themed-list').classList).toContain(
265+
await screen.findByText('War and Peace');
266+
expect(screen.getByTestId('themed-list').classList).toContain(
266267
'custom-class'
267268
);
268269
});

0 commit comments

Comments
 (0)