def test_performance(self): ''' Test the performance of the feedly system for multiple add_loves ''' start = datetime.datetime.now() notification_feedly = NotificationFeedly() loves = Love.objects.all()[:10] print loves.count() for love in loves: # run without the task notification_feedly._add_love(love) end = datetime.datetime.now() print end - start
def notification_add_love(love): from feedly.feed_managers.notification_feedly import NotificationFeedly feedly = NotificationFeedly() feedly._add_love(love)