code: def test_latency_updated_custom_ttl():
      """
      Invalidate the cached request.
  
      Test that the cache is empty
      """
      test_cache = DualCache()
      model_list = []
      cache_time = 3
      lowest_latency_logger = LowestLatencyLoggingHandler(
          router_cache=test_cache,
          model_list=model_list,
          routing_args={"ttl": cache_time},
      )
      model_group = "gpt-3.5-turbo"
      deployment_id = "1234"
      kwargs = {
          "litellm_params": {
              "metadata": {
                  "model_group": "gpt-3.5-turbo",
                  "deployment": "azure/chatgpt-v-2",
              },
              "model_info": {"id": deployment_id},
          }
      }
      start_time = time.time()
      response_obj = {"usage": {"total_tokens": 50}}
      time.sleep(5)
      end_time = time.time()
      lowest_latency_logger.log_success_event(
          response_obj=response_obj,
          kwargs=kwargs,
          start_time=start_time,
          end_time=end_time,
      )
      latency_key = f"{model_group}_map"
      print(f"cache: {test_cache.get_cache(key=latency_key)}")
      assert isinstance(test_cache.get_cache(key=latency_key), dict)
      time.sleep(cache_time)
      assert test_cache.get_cache(key=latency_key) is None
  
file_path: litellm/litellm/tests/test_lowest_latency_routing.py
imports: import sys, os, asyncio, time, random
  from datetime import datetime
  import traceback
  from dotenv import load_dotenv
  import os
  import pytest
  from litellm import Router
  import litellm
  from litellm.router_strategy.lowest_latency import LowestLatencyLoggingHandler
  from litellm.caching import DualCache
label_desc: Use image node_id 2 for calling a global function with example usage: test_latency_updated_custom_ttl() without return types