fakeNetworkEnv

tcmts.cli.test.e2e.contributions.fakeNetworkEnv · #ypmp3ipe · function · runs anywhere

What a server needs to look accounts up on a fake AT Protocol network: its directory, and leave to ask it over http on this machine.

import type { FakeNetwork } from "#codebase/tcmts/atproto/testing";

export const fakeNetworkEnv = (net: FakeNetwork): NodeJS.ProcessEnv => ({
  ATPROTO_DIRECTORY: net.url,
  ATPROTO_ALLOW_LOCAL: "1",
})

uses

used by