MockLanguageModelV1 is a Vercel AI SDK mock provider for testing generateText and generateObject without calling a live provider API. Define controlled model behavior by overriding doGenerate with predictable text, usage, and finish metadata. section 8.4.3
Test a predefined response
Instantiate MockLanguageModelV1 with doGenerate, pass it to generateText, and assert that result.text equals the expected response. The same pattern supports generateObject with a schema and object assertions. section 8.4.3
