def test_stream_complete(llm: GoogleGenAI) -> None:
    """Test both sync and async stream complete methods."""
    prompt = "Write a poem about a magic backpack"

    # Test synchronous stream complete
    sync_chunks = list(llm.stream_complete(prompt))
    assert len(sync_chunks) > 0
    assert all(isinstance(chunk.text, str) for chunk in sync_chunks)
Test both sync and async stream complete methods.
llama-index-integrations/llms/llama-index-llms-google-genai/tests/test_llms_google_genai.py