Skip to content

Commit

Permalink
Refactor App.test.jsx
Browse files Browse the repository at this point in the history
  • Loading branch information
SafdarJamal committed Jul 29, 2023
1 parent c8820e6 commit d1b52a4
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions src/App.test.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,13 @@ test('renders counter button', () => {
render(<App />);
const buttonElement = screen.getByText(/count is 0/i);
expect(buttonElement).toBeInTheDocument();
expect(buttonElement).toHaveTextContent(/count is 0/i);
screen.debug();
});

test('count increases on button click', () => {
render(<App />);
const buttonElement = screen.getByText(/count is 0/i);
fireEvent.click(buttonElement);
expect(buttonElement).toHaveTextContent(/count is 1/i);
screen.debug();

fireEvent.click(buttonElement);
expect(buttonElement).toHaveTextContent(/count is 2/i);
screen.debug();
});

test('renders learn react link', () => {
Expand Down

0 comments on commit d1b52a4

Please sign in to comment.