code: def test_run_with_params_streaming(
      self, chat_messages, mock_chat_completion_chunk
  ):
      streaming_callback_called = False
  
      def streaming_callback(chunk: StreamingChunk) -> None:
          nonlocal streaming_callback_called
          streaming_callback_called = True
  
      component = OpenAIChatGenerator(
          streaming_callback=streaming_callback
      )
      response = component.run(chat_messages)
  
      # check we called the streaming callback
      assert streaming_callback_called
  
      # check that the component still returns the correct response
      assert isinstance(response, dict)
      assert "replies" in response
      assert isinstance(response["replies"], list)
      assert len(response["replies"]) == 1
      assert [
          isinstance(reply, ChatMessage)
          for reply in response["replies"]
      ]
      assert "Hello" in response["replies"][0].content
  
imports: import os
  import pytest
  from openai import OpenAIError
  from haystack.components.generators.chat import OpenAIChatGenerator
  from haystack.components.generators.utils import default_streaming_callback
  from haystack.dataclasses import ChatMessage, StreamingChunk
label_desc: Use image node_id 11 for calling the TestOpenAIChatGenerator obj's underlying member method code with example usage: obj.test_run_with_params_streaming(chat_messages, mock_chat_completion_chunk) without return types