~ubuntu-branches/ubuntu/quantal/python-django/quantal-security

« back to all changes in this revision

Viewing changes to tests/regressiontests/utils/timesince.py

  • Committer: Bazaar Package Importer
  • Author(s): Jamie Strandboge
  • Date: 2010-10-12 11:34:35 UTC
  • mfrom: (1.2.7 upstream)
  • mto: This revision was merged to the branch mainline in revision 30.
  • Revision ID: james.westby@ubuntu.com-20101012113435-9lnsrh0i3mxozbt0
Tags: upstream-1.2.3
ImportĀ upstreamĀ versionĀ 1.2.3

Show diffs side-by-side

added added

removed removed

Lines of Context:
88
88
u'0 minutes'
89
89
 
90
90
# Timesince should work with both date objects (#9672)
91
 
>>> today = datetime.date.today() 
92
 
>>> timeuntil(today+oneday, today) 
93
 
u'1 day' 
94
 
>>> timeuntil(today-oneday, today) 
95
 
u'0 minutes' 
96
 
>>> timeuntil(today+oneweek, today) 
97
 
u'1 week' 
 
91
>>> today = datetime.date.today()
 
92
>>> timeuntil(today+oneday, today)
 
93
u'1 day'
 
94
>>> timeuntil(today-oneday, today)
 
95
u'0 minutes'
 
96
>>> timeuntil(today+oneweek, today)
 
97
u'1 week'
98
98
"""