code: def test__iter_over_pages__max_server_offset(get_single_page):
      # given
      get_single_page.side_effect = [
          generate_leaderboard_entries(values=["a", "b", "c"]),
          generate_leaderboard_entries(values=["d", "e"]),
          None,
      ]
  
      # when
      result = list(iter_over_pages(step_size=3, max_offset=5))
  
      # then
      assert result == generate_leaderboard_entries(
          values=["a", "b", "c", "d", "e"]
      )
      assert get_single_page.mock_calls == [
          call(
              offset=0, limit=3, sort_by="sys/id", searching_after=None
          ),
          call(
              offset=3, limit=2, sort_by="sys/id", searching_after=None
          ),
          call(
              offset=0, limit=3, sort_by="sys/id", searching_after="e"
          ),
      ]
  
file_path: neptune-client/tests/unit/neptune/new/api/test_searching_entries.py
imports: from typing import List, Sequence
  from mock import call, patch
  from neptune.api.searching_entries import iter_over_pages, to_leaderboard_entry
  from neptune.internal.backends.api_model import AttributeType, AttributeWithProperties, LeaderboardEntry
label_desc: Use image node_id 5 for calling a global function with example usage: test__iter_over_pages__max_server_offset(get_single_page) without return types