MCPcopy Create free account
hub / github.com/getsentry/sentry / test_delete

Method test_delete

tests/sentry/cache/test_cache.py:24–33  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

22 assert self.cache.get(self.cache_key) is True
23
24 def test_delete(self) -> None:
25 self.cache.set(self.cache_key, self.cache_val, 50)
26 assert self.cache.get(self.cache_key) == self.cache_val
27 self.cache.delete(self.cache_key)
28
29 assert self.cache.get(self.cache_key) is None
30
31 # Test deletion without an entry works
32 self.cache.delete(self.cache_key)
33 assert self.cache.get(self.cache_key) is None
34
35 def test_ttl(self) -> None:
36 self.cache.set(self.cache_key, self.cache_val, 0.1)

Callers

nothing calls this directly

Calls 3

setMethod · 0.65
getMethod · 0.65
deleteMethod · 0.45

Tested by

no test coverage detected