Skip to main content

protocol/testing/toxics

packages/protocol/src/testing/toxics

Purpose

Public barrel for Toxiproxy toxic profiles and control helpers.

Public surface

allToxicTags

Variable
All six toxic tags, enumerated for coverage assertions in Tier D.

defaultToxicProfile

Variable
Provides the default toxic profile runtime value.

makeToxiproxyClient

Function
Creates toxiproxy client. Returns: The created toxiproxy client.

ToxicControlError

Class
Toxiproxy HTTP API returned a non-2xx, or the control endpoint is down.

ToxicHandle

Interface
A live toxic attachment. Scoped: acquiring adds the toxic to the proxy, releasing the scope removes it. Tier D properties acquire a ToxicHandle inside Effect.scoped so a crashed property still cleans up.

ToxicProfile

TypeAlias
Represents toxic profile values.

ToxicTag

TypeAlias
Represents toxic tag values.

ToxiproxyClient

Interface
Describes toxiproxy client.

ToxiproxyConfig

Interface
Describes toxiproxy config.

ToxiproxyNetworkConfig

Interface
Describes toxiproxy network config.

ToxiproxyProxy

Interface
A live proxy that sits between TestClient and the real server (or between real client and TestServer). Acquiring the scope allocates an ephemeral port and registers the proxy; releasing deletes it.

Files

  • client.ts
  • defaults.ts
  • errors.ts
  • profile.ts