code: def block_generator(num_rows: int, num_blocks: int):
      for _ in range(num_blocks):
          yield pa.table({"foo": [1] * num_rows})
  
file_path: ray/python/ray/data/tests/block_batching/test_block_batching.py
imports: from typing import List
  from unittest import mock
  import pyarrow
  import pytest
  from ray.data._internal.block_batching.block_batching import BlockPrefetcher, _prefetch_blocks, batch_block_refs, batch_blocks
  from ray.data.block import Block
label_desc: Use image node_id 1 for calling a global function with example usage: block_generator(num_rows, num_blocks) without return types