class_docstr: Test ability to marshall ChatInput and ChatMessage protos.
class_docstr_tok: ["Test","ability","to","marshall","ChatInput","and","ChatMessage","protos","."]
docstr: Test that it is possible to set an image as avatar.
docstr_tok: ["Test","that","it","is","possible","to","set","an","image","as","avatar","."]
code: def test_image_avatar(self):
      """Test that it is possible to set an image as avatar."""
  
      message = st.chat_message(
          "cat",
          avatar="https://static.streamlit.io/examples/cat.jpg",
      )
  
      with message:
          pass
  
      message_block = self.get_delta_from_queue()
      self.assertEqual(message_block.add_block.chat_message.name, "cat")
      self.assertEqual(
          message_block.add_block.chat_message.avatar,
          "https://static.streamlit.io/examples/cat.jpg",
      )
      self.assertEqual(
          message_block.add_block.chat_message.avatar_type,
          BlockProto.ChatMessage.AvatarType.IMAGE,
      )
  
imports: import pytest
  from parameterized import parameterized
  import streamlit
  from streamlit.elements.utils import SESSION_STATE_WRITES_NOT_ALLOWED_ERROR_TEXT
  from streamlit.elements.widgets.chat import DISALLOWED_CONTAINERS_ERROR_TEXT
  from streamlit.errors import StreamlitAPIException
  from streamlit.proto.Block_pb2 import Block
  from streamlit.proto.ChatInput_pb2 import ChatInput
  from tests.delta_generator_test_case import DeltaGeneratorTestCase
label_desc: Use image node_id 8 for calling the ChatTest obj's underlying member method code with example usage: obj.test_image_avatar() without return types