code: def test_dataset_archive(tmpdir):
      """
      Test the dataset_archive determines if an archive is up to date
      """
      sig = "49b3fc3143d727d7819fabd4365d7e7b29794089dc9fa1e5e452aeb0b33d5eda"
      data_home = tmpdir.mkdir("fixtures")
  
      # When archive does not exist
      assert not dataset_archive("foo", sig, data_home=str(data_home))
  
      # Create archive
      fpath = data_home.join("foo.zip")
      fpath.write("this is a data archive")
  
      # When archive exists
      assert dataset_archive("foo", sig, data_home=data_home)
  
      # When archive does not match signature
      assert not dataset_archive("foo", "abcd", data_home=data_home)
  
file_path: yellowbrick/tests/test_datasets/test_path.py
imports: import os
  import pytest
  import contextlib
  from yellowbrick.datasets.path import *
  from yellowbrick.exceptions import DatasetsError
label_desc: Use image node_id 9 for calling a global function with example usage: test_dataset_archive(tmpdir) without return types