예제 #1
0
    def setUp(self):
        self.application = Application()
        self.pubsub = ZmqPubSub(self.application)
        self.pubsub.sub_stream = FakeSocket()

        self.project_id = 'test'
        self.namespace = 'test'
        self.channel = 'test'
예제 #2
0
 def setUp(self):
     super(ClientTest, self).setUp()
     self.client = TestClient(FakeSock(), {})
     self.client.is_authenticated = True
     self.client.project_id = "test_project"
     self.client.uid = "test_uid"
     self.client.user = "******"
     self.client.channels = {}
     self.client.presence_ping = FakePeriodic()
     self.client.application = Application()
     self.client.application.pubsub = ZmqPubSub(self.client.application)
     self.client.application.pubsub.sub_stream = FakeSocket()
     self.client.application.state = FakeState()