Skip to content

Commit

Permalink
chore: increase timeout for failing tests in CI
Browse files Browse the repository at this point in the history
tests pass locally without an increased timeout, but fail in CI
  • Loading branch information
danisharora099 committed Jul 24, 2024
1 parent 290a3ab commit ba7b44f
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 28 deletions.
1 change: 0 additions & 1 deletion packages/core/src/lib/health_manager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ class HealthManager implements IHealthManager {
}

private updateOverallHealth(): void {
//TODO: blocked for Store by https://github.com/waku-org/js-waku/pull/2019
const relevantProtocols = [Protocols.LightPush, Protocols.Filter];
const statuses = relevantProtocols.map(
(p) => this.getProtocolStatus(p)?.status
Expand Down
32 changes: 5 additions & 27 deletions packages/tests/tests/health-manager/protocols.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,8 @@ import {
const NUM_NODES = [0, 1, 2, 3];

describe("Health Manager", function () {
this.timeout(10_000);

let waku: LightNode;
let serviceNodes: ServiceNodesFleet;

Expand All @@ -26,8 +28,11 @@ describe("Health Manager", function () {
});

describe("Should update the health status for protocols", () => {
this.timeout(10_000);

NUM_NODES.map((num) => {
it(`LightPush with ${num} connections`, async function () {
this.timeout(10_000);
[serviceNodes, waku] = await runMultipleNodes(
this.ctx,
TestShardInfo,
Expand Down Expand Up @@ -75,33 +80,6 @@ describe("Health Manager", function () {
expect(health).to.not.equal(undefined);
}

if (num === 0) {
expect(health?.status).to.equal(HealthStatus.Unhealthy);
} else if (num < 2) {
expect(health?.status).to.equal(HealthStatus.MinimallyHealthy);
} else if (num >= 2) {
expect(health?.status).to.equal(HealthStatus.SufficientlyHealthy);
} else {
throw new Error("Invalid number of connections");
}
});
//TODO: blocked by https://github.com/waku-org/js-waku/pull/2019
it.skip(`Store with ${num} connections`, async function () {
[serviceNodes, waku] = await runMultipleNodes(
this.ctx,
TestShardInfo,
undefined,
undefined,
num
);

await waku.store.queryWithPromiseCallback([TestDecoder], () => {});

const health = waku.health.getProtocolStatus(Protocols.Store);
if (!health) {
expect(health).to.not.equal(undefined);
}

if (num === 0) {
expect(health?.status).to.equal(HealthStatus.Unhealthy);
} else if (num < 2) {
Expand Down

0 comments on commit ba7b44f

Please sign in to comment.