code: def test_cache_exceeds_size_but_not_in_database(
      tmp_path: Path,
      monkeypatch: MonkeyPatch,
      default_model_storage: ModelStorage,
  ):
      monkeypatch.setenv(CACHE_LOCATION_ENV, str(tmp_path))
  
      max_cache_size = 5
      # Pretend we have a cache of size `max_cached_size`
      monkeypatch.setenv(CACHE_SIZE_ENV, str(max_cache_size))
  
      cache = LocalTrainingCache()
  
      # Fill cache with something which is not in the cache metadata
      sub_dir = cache._cache_location / "some dir"
      sub_dir.mkdir()
  
      # one subdirectory which needs deletion
      tests.conftest.create_test_file_with_size(sub_dir, max_cache_size)
      # one file which needs deletion
      test_file = tests.conftest.create_test_file_with_size(
          cache._cache_location, max_cache_size
      )
  
      # Cache an item
      fingerprint_key = uuid.uuid4().hex
      output = TestCacheableOutput(
          {"something to cache": "dasdaasda"}, size_in_mb=2
      )
      output_fingerprint = uuid.uuid4().hex
      cache.cache_output(
          fingerprint_key,
          output,
          output_fingerprint,
          default_model_storage,
      )
  
      assert (
          cache.get_cached_output_fingerprint(fingerprint_key)
          == output_fingerprint
      )
      assert cache.get_cached_result(
          output_fingerprint, "some_node", default_model_storage
      )
      assert not sub_dir.is_dir()
      assert not test_file.is_file()
  
imports: import dataclasses
  import logging
  import shutil
  import uuid
  from pathlib import Path
  from typing import Dict, Text, Optional, Any, Callable
  from unittest.mock import Mock
  import pytest
  from _pytest.logging import LogCaptureFixture
  from _pytest.monkeypatch import MonkeyPatch
  from sqlalchemy.exc import OperationalError
  import rasa.shared.utils.io
  import rasa.shared.utils.common
  from rasa.engine.caching import LocalTrainingCache, CACHE_LOCATION_ENV, DEFAULT_CACHE_NAME, CACHE_SIZE_ENV, CACHE_DB_NAME_ENV, TrainingCache
  import tests.conftest
  from rasa.engine.storage.local_model_storage import LocalModelStorage
  from rasa.engine.storage.resource import Resource
  from rasa.engine.storage.storage import ModelStorage
label_desc: Use image node_id 13 for calling a global function with example usage: test_cache_exceeds_size_but_not_in_database(tmp_path, monkeypatch, default_model_storage) without return types