Skip to content
IC Reactor

FakeReplicaOptions

Defined in: core/src/testing/fake-replica.ts:95

Options for installFakeReplica.

optional host?: string

Defined in: core/src/testing/fake-replica.ts:105

The origin the fake answers for. Point the agents under test at it, for example with agentOptions: { host: replica.host }.

Where a ClientManager built with no host sends its calls: the page’s origin when the test environment has a local one (http://localhost:3000 in Vitest’s jsdom and happy-dom), and "http://127.0.0.1:4943" otherwise.


optional canisters?: Record<string, FakeCanister>

Defined in: core/src/testing/fake-replica.ts:111

The canisters the fake runs, by canister ID. A call to any other canister is rejected, as a replica rejects a call to a canister that does not exist.