class_docstr: Test MemorySessionStorage.
  
  These tests are intentionally extremely simple to ensure that we don't just end up
  testing cachetools.TTLCache. We try to just verify that we've wrapped TTLCache
  correctly, and in particular we avoid testing cache expiry functionality.
class_docstr_tok: ["Test","MemorySessionStorage",".","These","tests","are","intentionally","extremely","simple","to","ensure","that","we","do","n't","just","end","up","testing","cachetools.TTLCache",".","We","try","to","just","verify","that","we","'ve","wrapped","TTLCache","correctly",",","and","in","particular","we","avoid","testing","cache","expiry","functionality","."]
docstr: Verify that the backing cache of a MemorySessionStorage is a TTLCache.
  
  We do this because we're intentionally avoiding writing tests around cache
  expiry because the cachetools library should do this for us. In the case
  that the backing cache for a MemorySessionStorage ever changes, we'll likely be
  responsible for adding our own tests.
docstr_tok: ["Verify","that","the","backing","cache","of","a","MemorySessionStorage","is","a","TTLCache",".","We","do","this","because","we","'re","intentionally","avoiding","writing","tests","around","cache","expiry","because","the","cachetools","library","should","do","this","for","us",".","In","the","case","that","the","backing","cache","for","a","MemorySessionStorage","ever","changes",",","we","'ll","likely","be","responsible","for","adding","our","own","tests","."]
code: def test_uses_ttl_cache(self):
      """Verify that the backing cache of a MemorySessionStorage is a TTLCache.
  
      We do this because we're intentionally avoiding writing tests around cache
      expiry because the cachetools library should do this for us. In the case
      that the backing cache for a MemorySessionStorage ever changes, we'll likely be
      responsible for adding our own tests.
      """
      store = MemorySessionStorage()
      self.assertIsInstance(store._cache, TTLCache)
  
file_path: streamlit/lib/tests/streamlit/runtime/memory_session_storage_test.py
imports: import unittest
  from unittest.mock import MagicMock
  from cachetools import TTLCache
  from streamlit.runtime.memory_session_storage import MemorySessionStorage
label_desc: Use image node_id 1 for calling the MemorySessionStorageTest obj's underlying member method code with example usage: obj.test_uses_ttl_cache() without return types