Skip to content

Commit

Permalink
Test fix
Browse files Browse the repository at this point in the history
  • Loading branch information
UO287747 committed Feb 29, 2024
1 parent 19182b0 commit b50fa18
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions webapp/src/test/Game.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ describe('Question Component', () => {
const { getByText, getAllByRole } = render(<Game goTo={() => {}} />);

await waitFor(() => {
expect(getByText('Question: 1')).toBeInTheDocument();

});

await waitFor(() => {
Expand All @@ -19,14 +19,13 @@ describe('Question Component', () => {
const { getByText, getAllByRole } = render(<Game goTo={() => {}} />);

await waitFor(() => {
expect(getByText('Question: 1')).toBeInTheDocument();

});

const options = getAllByRole('listitem');
fireEvent.click(options[0]); // Select the first option


await waitFor(() => {
expect(getByText('Next')).toBeInTheDocument();

});

});
Expand All @@ -35,7 +34,7 @@ describe('Question Component', () => {
const { getByText, queryByText } = render(<Game goTo={() => {}} />);

await waitFor(() => {
expect(getByText('Question: 1')).toBeInTheDocument();

});

});
Expand Down

0 comments on commit b50fa18

Please sign in to comment.