docstr: Test that `fix_arrow_incompatible_column_types` correctly fixes
  columns containing mixed types by converting them to string.
docstr_tok: ["Test","that","`","fix_arrow_incompatible_column_types","`","correctly","fixes","columns","containing","mixed","types","by","converting","them","to","string","."]
code: def test_fix_mixed_column_types(self):
      """Test that `fix_arrow_incompatible_column_types` correctly fixes
      columns containing mixed types by converting them to string.
      """
      df = pd.DataFrame(
          {
              "mixed-integer": [1, "foo", 3],
              "mixed": [1.0, "foo", 3],
              "integer": [1, 2, 3],
              "float": [1.0, 2.1, 3.2],
              "string": ["foo", "bar", None],
          },
          index=[1.0, "foo", 3],
      )
  
      fixed_df = type_util.fix_arrow_incompatible_column_types(df)
  
      # Check dtypes
      self.assertIsInstance(
          fixed_df["mixed-integer"].dtype, pd.StringDtype
      )
      self.assertIsInstance(fixed_df["mixed"].dtype, pd.StringDtype)
      self.assertTrue(
          pd.api.types.is_integer_dtype(fixed_df["integer"].dtype)
      )
      self.assertTrue(
          pd.api.types.is_float_dtype(fixed_df["float"].dtype)
      )
      self.assertTrue(
          pd.api.types.is_object_dtype(fixed_df["string"].dtype)
      )
      self.assertEqual(fixed_df.index.dtype.kind, "O")
  
      # Check inferred types:
      self.assertEqual(infer_dtype(fixed_df["mixed-integer"]), "string")
      self.assertEqual(infer_dtype(fixed_df["mixed"]), "string")
      self.assertEqual(infer_dtype(fixed_df["integer"]), "integer")
      self.assertEqual(infer_dtype(fixed_df["float"]), "floating")
      self.assertEqual(infer_dtype(fixed_df["string"]), "string")
      self.assertEqual(infer_dtype(fixed_df.index), "string")
  
imports: import enum
  import unittest
  from collections import namedtuple
  from datetime import date
  from decimal import Decimal
  from typing import Any
  from unittest.mock import patch
  import numpy
  import pandas
  import plotly.graph_objs
  import pytest
  from pandas.api.types import infer_dtype
  from parameterized import parameterized
  from streamlit import errors, type_util
  from streamlit.errors import StreamlitAPIException
  from tests.streamlit.data_mocks import BASE_TYPES_DF, DATETIME_TYPES_DF, INTERVAL_TYPES_DF, LIST_TYPES_DF, NUMBER_TYPES_DF, PERIOD_TYPES_DF, SHARED_TEST_CASES, SPECIAL_TYPES_DF, UNSUPPORTED_TYPES_DF, TestCaseMetadata, TestObject
  from tests.streamlit.snowpark_mocks import DataFrame
  from tests.streamlit.snowpark_mocks import Row
  from tests.testutil import create_snowpark_session, patch_config_options
label_desc: Use image node_id 22 for calling the TypeUtilTest obj's underlying member method code with example usage: obj.test_fix_mixed_column_types() without return types