MCPcopy
hub / github.com/django/django / test_get_or_set

Method test_get_or_set

tests/cache/tests.py:279–281  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

277 cache.decr_version("does_not_exist")
278
279 def test_get_or_set(self):
280 self.assertEqual(cache.get_or_set("mykey", "default"), "default")
281 self.assertIsNone(cache.get_or_set("mykey", None))
282
283 def test_get_or_set_callable(self):
284 def my_callable():

Callers

nothing calls this directly

Calls 1

get_or_setMethod · 0.80

Tested by

no test coverage detected