def test_timesince(): month_ago = datetime.now() - timedelta(days=30) assert helpers.timesince(month_ago) == u'1 month ago' assert helpers.timesince(None) == u''
def test_timesince(): month_ago = datetime.now() - timedelta(days=30) eq_(helpers.timesince(month_ago), u'1 month ago') eq_(helpers.timesince(None), u'')
def test_timesince(): month_ago = datetime.now() - timedelta(days=30) eq_(helpers.timesince(month_ago), u'1 month ago') eq_(helpers.timesince(None), u'')
def test_timesince(): month_ago = datetime.now() - timedelta(days=30) assert helpers.timesince(month_ago) == u'1 month ago' assert helpers.timesince(None) == u''