MCPcopy
hub / github.com/django/django / test_session_get_decoded

Method test_session_get_decoded

tests/sessions_tests/tests.py:681–691  ·  view source on GitHub ↗

Test we can use Session.get_decoded to retrieve data stored in normal way

(self)

Source from the content-addressed store, hash-verified

679 self.assertEqual(str(s), session_key)
680
681 def test_session_get_decoded(self):
682 """
683 Test we can use Session.get_decoded to retrieve data stored
684 in normal way
685 """
686 self.session["x"] = 1
687 self.session.save()
688
689 s = self.model.objects.get(session_key=self.session.session_key)
690
691 self.assertEqual(s.get_decoded(), {"x": 1})
692
693 def test_sessionmanager_save(self):
694 """

Callers

nothing calls this directly

Calls 3

get_decodedMethod · 0.80
saveMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected