tests/test-template-functions.t
changeset 48970 9987d14ad63f
parent 48967 42d2b31cee0b
child 49505 c96ed4029fda
equal deleted inserted replaced
48969:0583d7f0fdff 48970:9987d14ad63f
   190 
   190 
   191   $ hg init unstable-hash
   191   $ hg init unstable-hash
   192   $ cd unstable-hash
   192   $ cd unstable-hash
   193   $ hg log --template '{date|age}\n' > /dev/null || exit 1
   193   $ hg log --template '{date|age}\n' > /dev/null || exit 1
   194 
   194 
   195   >>> from __future__ import absolute_import
       
   196   >>> import datetime
   195   >>> import datetime
   197   >>> fp = open('a', 'wb')
   196   >>> fp = open('a', 'wb')
   198   >>> n = datetime.datetime.now() + datetime.timedelta(366 * 7)
   197   >>> n = datetime.datetime.now() + datetime.timedelta(366 * 7)
   199   >>> fp.write(b'%d-%d-%d 00:00' % (n.year, n.month, n.day)) and None
   198   >>> fp.write(b'%d-%d-%d 00:00' % (n.year, n.month, n.day)) and None
   200   >>> fp.close()
   199   >>> fp.close()