def test_get_existing_session(self):
     store = SessionStore(self.datadir, self.hub)
     # Create a new session.
     new_session = store.get('foo')
     # Get the same existing session again.
     got_session = store.get('foo')
     self.assertEqual(new_session, got_session)
Beispiel #2
0
 def test_get_existing_session(self):
     store = SessionStore(self.datadir, self.hub)
     # Create a new session.
     new_session = store.get('foo')
     # Get the same existing session again.
     got_session = store.get('foo')
     self.assertEqual(new_session, got_session)
 def test_get_all_sessions(self):
     store = SessionStore(self.datadir, self.hub)
     # Create a new session.
     foo_session = store.get('foo')
     bar_session = store.get('bar')
     self.assertEqual([foo_session, bar_session], store.get_all())
 def test_get_new_session(self):
     store = SessionStore(self.datadir, self.hub)
     self.assertFalse(store.exists('foo'))
     store.get('foo')
     self.assertTrue(store.exists('foo'))
Beispiel #5
0
 def test_get_all_sessions(self):
     store = SessionStore(self.datadir, self.hub)
     # Create a new session.
     foo_session = store.get('foo')
     bar_session = store.get('bar')
     self.assertEqual([foo_session, bar_session], store.get_all())
Beispiel #6
0
 def test_get_new_session(self):
     store = SessionStore(self.datadir, self.hub)
     self.assertFalse(store.exists('foo'))
     store.get('foo')
     self.assertTrue(store.exists('foo'))