MCPcopy
hub / github.com/marimo-team/marimo / one

Method one

tests/_save/test_cache.py:276–288  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

274
275 @app.cell
276 def one() -> tuple[int]:
277 # Check top level import
278 from marimo import persistent_cache
279 from tests._save.loaders.mocks import MockLoader
280
281 with persistent_cache(name="one", _loader=MockLoader()) as cache:
282 Y = 8
283 X = 7
284 assert X == 7
285 assert cache._cache.defs == {"X": 7, "Y": 8}
286 assert cache.loader._saved
287 assert not cache.loader._loaded
288 return X, Y, persistent_cache
289
290 # Coverage's trace override conflicts with cache introspection. Letting
291 # the first test fail seems to fix this issue.

Callers

nothing calls this directly

Calls 3

persistent_cacheFunction · 0.90
MockLoaderClass · 0.90
cacheMethod · 0.80

Tested by

no test coverage detected