docstr: Test output from CLI scan cache when cache does not exist.
  
  End-to-end test just to see if output is in expected format.
docstr_tok: ["Test","output","from","CLI","scan","cache","when","cache","does","not","exist",".","End-to-end","test","just","to","see","if","output","is","in","expected","format","."]
code: def test_cli_scan_missing_cache(self) -> None:
      """Test output from CLI scan cache when cache does not exist.
  
      End-to-end test just to see if output is in expected format.
      """
      tmp_dir = tempfile.mkdtemp()
      os.rmdir(tmp_dir)
  
      args = Mock()
      args.verbose = 0
      args.dir = tmp_dir
  
      with capture_output() as output:
          ScanCacheCommand(args).run()
  
      expected_output = f"""
          Cache directory not found: {Path(tmp_dir).resolve()}
          """
  
      self.assertListEqual(
          output.getvalue().split(), expected_output.split()
      )
  
imports: import os
  import tempfile
  import time
  import unittest
  from pathlib import Path
  from unittest.mock import Mock
  import pytest
  from huggingface_hub._snapshot_download import snapshot_download
  from huggingface_hub.commands.scan_cache import ScanCacheCommand
  from huggingface_hub.utils import DeleteCacheStrategy, HFCacheInfo, capture_output, scan_cache_dir
  from huggingface_hub.utils._cache_manager import CacheNotFound, _format_size, _format_timesince, _try_delete_path
  from .testing_constants import TOKEN
  from .testing_utils import rmtree_with_retry, with_production_testing, xfail_on_windows
label_desc: Use image node_id 6 for calling the TestValidCacheUtils obj's underlying member method code with example usage: obj.test_cli_scan_missing_cache() without return types