def test_cache_length(self):
        """Test the length of the cache for both cache types."""
        for cache_type, cache in self.caches.items():
            with self.subTest(cache_type=cache_type):
                cache.set('key1', 'value1')
                cache.set('key2', 'value2')
                self.assertEqual(len(cache), 2, f"{cache_type} cache length is incorrect.")
Test the length of the cache for both cache types.
tests/integ_tests/core/inference/test_cache.py