Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the new tests and fixes to the main branch #273

Merged
merged 15 commits into from
Apr 22, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
fix: Fixing dashboard tests
sergiorodriguezgarcia committed Apr 21, 2024
commit ce8276af1bd0b7708c34b58dc4f52d9230fe7312
5 changes: 2 additions & 3 deletions webapp/src/tests/Dashboard.test.js
Original file line number Diff line number Diff line change
@@ -80,7 +80,7 @@ describe('Dashboard', () => {
test('renders Play button when game is active', async () => {

mockAxios.onGet(`${api}/games/is-active`).reply(HttpStatusCode.Ok, {
"is_active": true
"is_active": false
});

mockAxios.onGet(`${api}/games/gamemodes`).reply(HttpStatusCode.Ok, {
@@ -119,7 +119,7 @@ describe('Dashboard', () => {

test('renders Resume button when game is not active', async () => {
mockAxios.onGet(`${api}/games/is-active`).reply(HttpStatusCode.Ok, {
"is_active": false
"is_active": true
});

mockAxios.onGet(`${api}/games/gamemodes`).reply(HttpStatusCode.Ok, {
@@ -151,7 +151,6 @@ describe('Dashboard', () => {
</ChakraProvider>
);

// FIXME: This does not pass
await waitFor(() => {
expect(container.querySelector('#resumeBtn')).toBeInTheDocument();
});