Пример #1
0
 def test_key(self):
     self.assertEqual(self.stream.key, "sh:streams:local:%s" % self.other_user.id)
     stream = LocalStream(user=AnonymousUser())
     self.assertEqual(stream.key, "sh:streams:local:anonymous")
Пример #2
0
 def get_content(self):
     stream = LocalStream(last_id=self.last_id, user=self.request.user)
     return stream.get_content()
Пример #3
0
 def setUp(self):
     super().setUp()
     self.stream = LocalStream(user=self.other_user)