Skip to content
docs

Swap2BehaviourFixture

Defined in: behaviour-suite.ts:22

optional account?: MockAccountOptions

Defined in: behaviour-suite.ts:29

Signing mock account (address/chain must match what the recorded quote binds).


optional depositAddress?: string

Defined in: behaviour-suite.ts:33

Deposit-address providers: the address the recorded quote declares.


fetch: {(input, init?): Promise<Response>; (input, init?): Promise<Response>; }

Defined in: behaviour-suite.ts:27

Recorded/mocked network for this fixture, installed as the global fetch.

(input, init?): Promise<Response>

MDN Reference

RequestInfo | URL

RequestInit

Promise<Response>

(input, init?): Promise<Response>

MDN Reference

string | Request | URL

RequestInit

Promise<Response>


name: string

Defined in: behaviour-suite.ts:23


options: Record<string, unknown>

Defined in: behaviour-suite.ts:25

Swap2Options for swap2() / quoteSwap2() (include minAmountOut).


optional own?: string[]

Defined in: behaviour-suite.ts:31

The user’s other addresses (e.g. the destination-chain recipient). The signing account is always own.


optional serialized?: (serializedTx, own) => void | Promise<void>

Defined in: behaviour-suite.ts:43

Provider-serialized legs (Solana aggregators): decode what the account would be asked to sign and assert it (fee payer, signers, programs, amounts). Required when the plan’s source is serialized — opaque bytes are not accepted unread.

string

ReadonlySet<string>

void | Promise<void>


optional sourceToken?: string

Defined in: behaviour-suite.ts:37

Source token contract; omit for the native coin.


optional spender?: string

Defined in: behaviour-suite.ts:35

Calldata providers: the approval spender the recorded quote declares (none → no approval allowed).