Skip to content

Commit

Permalink
test: fix provider test references
Browse files Browse the repository at this point in the history
  • Loading branch information
andy-haynes committed Sep 5, 2024
1 parent c4f05cd commit 6eb79e3
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions packages/core/src/lib/wallet-selector.spec.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
import { setupWalletSelector } from "./wallet-selector";
import { FailoverRpcProvider } from "@near-js/providers";
import { getNetworkPreset } from "./options";
import { JsonRpcProvider } from "near-api-js/lib/providers";
import {
FailoverRpcProvider,
JsonRpcProvider,
} from "near-api-js/lib/providers";
import type { Network } from "./options.types";
import type { Store } from "./store.types";
import type { WalletModuleFactory } from "./wallet";
Expand Down Expand Up @@ -52,8 +54,8 @@ jest.mock("./store", () => {
};
});

jest.mock("@near-js/providers", () => {
const originalModule = jest.requireActual("@near-js/providers");
jest.mock("near-api-js/lib/providers", () => {
const originalModule = jest.requireActual("near-api-js/lib/providers");
return {
...originalModule,
FailoverRpcProvider: jest.fn(),
Expand Down

0 comments on commit 6eb79e3

Please sign in to comment.