Skip to content

Commit

Permalink
fix(tests): use proper projectId env var injection
Browse files Browse the repository at this point in the history
  • Loading branch information
bkrem committed Jan 2, 2025
1 parent 91ae5ca commit e831c40
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 5 additions & 1 deletion jsonrpc/provider/test/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,10 @@ import { fromString } from "uint8arrays/from-string";

import JsonRpcProvider from "../src";

if (!process.env.TEST_PROJECT_ID) {
throw new Error("TEST_PROJECT_ID env var not set");
}

chai.use(chaiAsPromised);

const TEST_RANDOM_HOST = "random.domain.that.does.not.exist";
Expand Down Expand Up @@ -63,7 +67,7 @@ describe("@walletconnect/jsonrpc-provider", () => {
version: 2,
sdkVersion: version,
relayUrl: TEST_URL.ws.good,
projectId: "3cbaa32f8fbf3cdcc87d27ca1fa68069",
projectId: process.env.TEST_PROJECT_ID,
auth,
});

Expand Down
6 changes: 5 additions & 1 deletion jsonrpc/ws-connection/test/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,10 @@ import { fromString } from "uint8arrays/from-string";

chai.use(chaiAsPromised);

if (!process.env.TEST_PROJECT_ID) {
throw new Error("TEST_PROJECT_ID env var not set");
}

const BASE16 = "base16";

function generateRandomBytes32(): string {
Expand All @@ -35,7 +39,7 @@ const formatRelayUrl = async () => {
version: 2,
sdkVersion: version,
relayUrl: RELAY_URL,
projectId: "3cbaa32f8fbf3cdcc87d27ca1fa68069",
projectId: process.env.TEST_PROJECT_ID,
auth,
});
};
Expand Down

0 comments on commit e831c40

Please sign in to comment.