Esempio n. 1
0
 def test_retrieve_station_in_memcache(self):
     memcache.add("poll-station-%s-%s" % ("Caltex", "EMBA"),self.station)
     self.model_poll_props(views.retrieve_station_from_memcache_or_db("EMBA", "Caltex"))
Esempio n. 2
0
 def test_retrieve_station_with_none(self):
     self.assertEqual(None, views.retrieve_station_from_memcache_or_db(None, None))
Esempio n. 3
0
 def test_retrieve_station_in_db(self):
     self.station.put()
     self.model_poll_props(views.retrieve_station_from_memcache_or_db("EMBA", "Caltex"))