code: def test_scroll_server_results():
      result = list(
          neurovault._scroll_server_results(
              neurovault._NEUROVAULT_COLLECTIONS_URL,
              max_results=6,
              batch_size=3,
          )
      )
  
      assert len(result) == 6
  
      result = list(
          neurovault._scroll_server_results(
              neurovault._NEUROVAULT_COLLECTIONS_URL,
              max_results=3,
              local_filter=lambda r: False,
          )
      )
      assert not result
  
      no_results = neurovault._scroll_server_results(
          "http://BAD_URL", max_results=3, local_filter=lambda r: True
      )
      next(no_results)
  
imports: import hashlib
  import json
  import os
  import re
  import stat
  from urllib import parse
  import numpy
  import pandas
  import pytest
  import requests
  from nilearn._utils.data_gen import generate_fake_fmri
  from nilearn.conftest import _rng
  from nilearn.datasets import neurovault
  from nilearn.image import load_img
label_desc: Use image node_id 14 for calling a global function with example usage: test_scroll_server_results() without return types