code: def test_pivot_duplicate_names_7731() -> None:
      df = pl.DataFrame(
          {
              "a": [1, 4],
              "b": [1.5, 2.5],
              "c": ["x", "x"],
              "d": [7, 8],
              "e": ["x", "y"],
          }
      )
      assert df.pivot(
          values=cs.integer(),
          index=cs.float(),
          columns=cs.string(),
          aggregate_function="first",
      ).to_dict(as_series=False) == {
          "b": [1.5, 2.5],
          "a_c_x": [1, 4],
          "d_c_x": [7, 8],
          "a_e_x": [1, None],
          "a_e_y": [None, 4],
          "d_e_x": [7, None],
          "d_e_y": [None, 8],
      }
  
imports: from __future__ import annotations
  from datetime import date, datetime, timedelta
  from typing import TYPE_CHECKING, Any
  import pytest
  import polars
  import polars.selectors
  from polars.exceptions import ComputeError
  from polars.testing import assert_frame_equal
label_desc: Use image node_id 7 for calling a global function with example usage: test_pivot_duplicate_names_7731() without return types