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