code: def environ(**env):
      """
      Temporarily set the environment variables for a test, restoring them when
      the test is complete (e.g. when the context manager exits).
  
      Parameters
      ----------
      env : dict
          The environment variables that should exist in context
      """
      old_env = dict(os.environ)
      os.environ.clear()
      os.environ.update(env)
  
      try:
          yield
      finally:
          os.environ.clear()
          os.environ.update(old_env)
  
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 1 for calling a global function with example usage: environ() without return types