Skip to main content

Module mock

Module mock 

Source
Expand description

Mock provider for testing — dequeues pre-configured responses.

MockProvider is constructed with a list of CompletionResponses. Each call to complete pops the next one from the queue and records the request it received. Running out of responses returns a provider error — making it easy to assert “the test exercised exactly N turns”.

Structs§

MockProvider
A ModelProvider that returns pre-configured responses from a queue.