code: def test_check_md5():
      fd, fname = tempfile.mkstemp()
      stored_md5 = fetcher._get_file_md5(fname)
      # If all is well, this shouldn't return anything:
      npt.assert_equal(fetcher.check_md5(fname, stored_md5), None)
      # If None is provided as input, it should silently not check either:
      npt.assert_equal(fetcher.check_md5(fname, None), None)
      # Otherwise, it will raise its exception class:
      npt.assert_raises(
          fetcher.FetcherError, fetcher.check_md5, fname, "foo"
      )
  
file_path: dipy/dipy/data/tests/test_fetcher.py
imports: from http.server import HTTPServer, SimpleHTTPRequestHandler
  import os
  import os.path
  from threading import Thread
  import tempfile
  from urllib.request import pathname2url
  import numpy.testing
  from dipy.data import SPHERE_FILES
  import dipy.data.fetcher
label_desc: Use image node_id 1 for calling a global function with example usage: test_check_md5() without return types