mirror of
https://github.com/apache/superset.git
synced 2024-09-07 06:17:45 -04:00
test: Fixes act errors in Alert test (#21386)
This commit is contained in:
parent
25188c42e0
commit
75d5da8898
@ -64,13 +64,14 @@ test('renders without icon', async () => {
|
||||
});
|
||||
});
|
||||
|
||||
test('renders message', () => {
|
||||
test('renders message', async () => {
|
||||
render(<Alert message="Message" />);
|
||||
expect(screen.getByRole('alert')).toHaveTextContent('Message');
|
||||
expect(await screen.findByRole('alert')).toHaveTextContent('Message');
|
||||
});
|
||||
|
||||
test('renders message and description', () => {
|
||||
test('renders message and description', async () => {
|
||||
render(<Alert message="Message" description="Description" />);
|
||||
expect(screen.getByRole('alert')).toHaveTextContent('Message');
|
||||
expect(screen.getByRole('alert')).toHaveTextContent('Description');
|
||||
const alert = await screen.findByRole('alert');
|
||||
expect(alert).toHaveTextContent('Message');
|
||||
expect(alert).toHaveTextContent('Description');
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user