def test_setAndGetItem(self):
        """Test setting an item and then getting it for both cache types."""
        for cache_type, cache in self.caches.items():
            with self.subTest(cache_type=cache_type):
                cache.set('key1', 'value1')
                self.assertEqual(cache.get('key1'), 'value1', f"Failed in {cache_type} cache.")
Test setting an item and then getting it for both cache types.
tests/integ_tests/core/inference/test_cache.py