Skip to content

Commit

Permalink
Fix unit test
Browse files Browse the repository at this point in the history
  • Loading branch information
tassoevan committed Jan 24, 2025
1 parent 9e34957 commit fef266f
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ it('should render data as progress bars', async () => {
await userEvent.click(screen.getByRole('button', { name: 'Click_here_for_more_info' }));

expect(screen.getByRole('link', { name: 'premium plans' })).toHaveAttribute('href', PRICING_LINK);

// TODO: discover how to automatically unmount all modals after each test
await userEvent.click(screen.getByRole('button', { name: 'Close' }));
});

it('should render an upgrade button if marketplace apps reached 80% of the limit', async () => {
Expand All @@ -53,6 +56,9 @@ it('should render an upgrade button if marketplace apps reached 80% of the limit
await userEvent.click(screen.getByRole('button', { name: 'Click_here_for_more_info' }));

expect(screen.getByRole('link', { name: 'premium plans' })).toHaveAttribute('href', PRICING_LINK);

// TODO: discover how to automatically unmount all modals after each test
await userEvent.click(screen.getByRole('button', { name: 'Close' }));
});

it('should render a full progress bar with private apps disabled', async () => {
Expand All @@ -75,4 +81,7 @@ it('should render a full progress bar with private apps disabled', async () => {
await userEvent.click(screen.getByRole('button', { name: 'Click_here_for_more_info' }));

expect(screen.getByRole('link', { name: 'premium plans' })).toHaveAttribute('href', PRICING_LINK);

// TODO: discover how to automatically unmount all modals after each test
await userEvent.click(screen.getByRole('button', { name: 'Close' }));
});

0 comments on commit fef266f

Please sign in to comment.