code: def test_get_temp_dir_environment():
      from skift.util import get_temp_dir_name, SKIFT_TEMP_DIR_ENV_VAR
      import os
      import shutil
      import tempfile
  
      try:
          # Save the existing Skift temp dir env var
          env_var = os.environ[SKIFT_TEMP_DIR_ENV_VAR]
          del os.environ[SKIFT_TEMP_DIR_ENV_VAR]
      except KeyError:
          env_var = None
  
      # Create a temporary directory for the test
      test_tempdir = tempfile.mkdtemp()
      os.environ[SKIFT_TEMP_DIR_ENV_VAR] = test_tempdir
  
      # Should use the temp dir from the environment variable
      assert test_tempdir == get_temp_dir_name()
  
      if env_var:
          os.environ[SKIFT_TEMP_DIR_ENV_VAR] = env_var
      else:
          del os.environ[SKIFT_TEMP_DIR_ENV_VAR]
  
      shutil.rmtree(test_tempdir)
  
imports: import pytest
  import pandas
  from sklearn.model_selection import cross_val_score
  from skift import FirstColFtClassifier, IdxBasedFtClassifier, ColLblBasedFtClassifier, FirstObjFtClassifier, SeriesFtClassifier
label_desc: Use image node_id 21 for calling a global function with example usage: test_get_temp_dir_environment() without return types