code: def test_pivot() -> None:
      df = pl.DataFrame(
          {
              "foo": ["A", "A", "B", "B", "C"],
              "N": [1, 2, 2, 4, 2],
              "bar": ["k", "l", "m", "n", "o"],
          }
      )
      result = df.pivot(
          values="N",
          index="foo",
          columns="bar",
          aggregate_function=None,
      )
  
      expected = pl.DataFrame(
          [
              ("A", 1, 2, None, None, None),
              ("B", None, None, 2, 4, None),
              ("C", None, None, None, None, 2),
          ],
          schema=["foo", "k", "l", "m", "n", "o"],
      )
      assert_frame_equal(result, expected)
  
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 1 for calling a global function with example usage: test_pivot() without return types