Skip to content

Commit

Permalink
Merge 671adf1 into d101913
Browse files Browse the repository at this point in the history
  • Loading branch information
nazarhussain authored Jun 14, 2024
2 parents d101913 + 671adf1 commit 0ffe333
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion packages/light-client/test/unit/webEsmBundle.browser.test.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,16 @@
/* eslint-disable @typescript-eslint/no-unsafe-assignment,@typescript-eslint/no-unsafe-member-access,@typescript-eslint/no-unsafe-call */
import {expect, describe, it, vi} from "vitest";
import {expect, describe, it, vi, beforeAll} from "vitest";
import {sleep} from "@lodestar/utils";
import {Lightclient, LightclientEvent, utils, transport} from "../../dist/lightclient.min.mjs";

describe("web bundle for lightclient", () => {
vi.setConfig({testTimeout: 20_000});

// Sometimes bundle takes some time to load in the browser
beforeAll(async () => {
await sleep(2000);
});

it("should have a global interface", () => {
expect((window as any)["lodestar"]["lightclient"]).toBeDefined();
});
Expand Down

0 comments on commit 0ffe333

Please sign in to comment.