Skip to content
This repository was archived by the owner on Mar 28, 2022. It is now read-only.

Commit e4a1dfe

Browse files
committed
test(e2e): Fix flaky test
1 parent db483bd commit e4a1dfe

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

test/e2e/stop-plugin.spec.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ describe("when stopping plugin", () => {
3131
describe("when stopped", () => {
3232
it("should respond not found when requesting setting", async () => {
3333
await server._stopPlugins();
34+
await waitForServer();
3435
const response = await fetch("/admin/settings");
3536
expect(response.status).toEqual(404);
3637
});
@@ -64,6 +65,7 @@ describe("when stopping plugin", () => {
6465

6566
it("should have not started the plugin", async () => {
6667
await server._stopPlugins();
68+
await waitForServer();
6769
const response = await fetch("/admin/settings");
6870
expect(response.status).toEqual(404);
6971
});
@@ -72,6 +74,7 @@ describe("when stopping plugin", () => {
7274
describe("when plugins are started", () => {
7375
it("should respond with same mock", async () => {
7476
await server._startPlugins();
77+
await waitForServer();
7578
const response = await fetch("/api/users/2");
7679
expect(response.body).toEqual({
7780
id: 2,

0 commit comments

Comments
 (0)