Skip to content

Commit

Permalink
udate test
Browse files Browse the repository at this point in the history
  • Loading branch information
shahzad31 committed May 6, 2022
1 parent b2ff9d1 commit f6dea01
Showing 1 changed file with 0 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -6,23 +6,10 @@
*/

import React from 'react';
import { fireEvent, waitFor } from '@testing-library/react';
import { render } from '../../../utils/testing/rtl_helpers';
import { ActionMenuContent } from './action_menu_content';

describe('ActionMenuContent', () => {
it('renders alerts dropdown', async () => {
const { getByLabelText, getByText } = render(<ActionMenuContent />);

const alertsDropdown = getByLabelText('Open alerts and rules context menu');
fireEvent.click(alertsDropdown);

await waitFor(() => {
expect(getByText('Create rule'));
expect(getByText('Manage rules'));
});
});

it('renders settings link', () => {
const { getByRole, getByText } = render(<ActionMenuContent />);

Expand Down

0 comments on commit f6dea01

Please sign in to comment.