code: def test_format() -> None:
      df = pl.DataFrame({"a": ["a", "b", "c"], "b": [1, 2, 3]})
  
      out = df.select(
          [pl.format("foo_{}_bar_{}", pl.col("a"), "b").alias("fmt")]
      )
      assert out["fmt"].to_list() == [
          "foo_a_bar_1",
          "foo_b_bar_2",
          "foo_c_bar_3",
      ]
  
imports: from __future__ import annotations
  from datetime import date, datetime
  from typing import TYPE_CHECKING
  import pytest
  import polars
  from polars.testing import assert_frame_equal, assert_series_equal
label_desc: Use image node_id 27 for calling a global function with example usage: test_format() without return types