code: def test_row_count(foods_parquet_path: Path) -> None:
      df = pl.read_parquet(
          foods_parquet_path, row_count_name="row_count"
      )
      assert df["row_count"].to_list() == list(range(27))
  
      df = (
          pl.scan_parquet(
              foods_parquet_path, row_count_name="row_count"
          )
          .filter(pl.col("category") == pl.lit("vegetables"))
          .collect()
      )
  
      assert df["row_count"].to_list() == [0, 6, 11, 13, 14, 20, 25]
  
      df = (
          pl.scan_parquet(
              foods_parquet_path, row_count_name="row_count"
          )
          .with_row_count("foo", 10)
          .filter(pl.col("category") == pl.lit("vegetables"))
          .collect()
      )
  
      assert df["foo"].to_list() == [10, 16, 21, 23, 24, 30, 35]
  
imports: from __future__ import annotations
  from collections import OrderedDict
  from pathlib import Path
  from typing import TYPE_CHECKING, Any
  import pandas
  import pytest
  import polars
  from polars.testing import assert_frame_equal
label_desc: Use image node_id 5 for calling a global function with example usage: test_row_count(foods_parquet_path) without return types