16 tests covering provider selection, context injection, sendMessage streaming, error handling, stop generation, and web search integration. Mocks fetch/SSE and IDB for isolated testing. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>