예제 #1
0
    def publish_one(self, client, topic):
        t = PubSubTopic.find(topic)

        if t:
            logger.debug('publishing data once for %s to %s', topic, client)
            client.send(topic, t.payload(use_cache=True, name=topic))
예제 #2
0
  def publish_one(self, client, topic):
    t = PubSubTopic.find(topic)

    if t:
      logger.debug('publishing data once for %s to %s', topic, client)
      client.send(topic, t.payload(useCache=True, name=topic))
예제 #3
0
 def test_not_exists(self):
   self.assertEqual(PubSubTopic.find("foobar"), None)
예제 #4
0
  def test_exists(self):
    topic = PubSubTopic("foo", None, None)

    self.assertEqual(PubSubTopic.find("foo"), topic)
예제 #5
0
    def test_exists(self):
        topic = PubSubTopic("foo", None, None)

        self.assertEqual(PubSubTopic.find("foo"), topic)
예제 #6
0
 def test_not_exists(self):
     self.assertEqual(PubSubTopic.find("foobar"), None)