code: def test_rank_random_expr() -> None:
      df = pl.from_dict(
          {
              "a": [1] * 5,
              "b": [1, 2, 3, 4, 5],
              "c": [200, 100, 100, 50, 100],
          }
      )
  
      df_ranks1 = df.with_columns(
          pl.col("c")
          .rank(method="random", seed=1)
          .over("a")
          .alias("rank")
      )
      df_ranks2 = df.with_columns(
          pl.col("c")
          .rank(method="random", seed=1)
          .over("a")
          .alias("rank")
      )
      assert_frame_equal(df_ranks1, df_ranks2)
  
file_path: polars/py-polars/tests/unit/operations/test_random.py
imports: from __future__ import annotations
  import pytest
  import polars
  from polars.testing import assert_frame_equal, assert_series_equal
label_desc: Use image node_id 7 for calling a global function with example usage: test_rank_random_expr() without return types