[Checkins] SVN: zope.dublincore/trunk/src/zope/dublincore/tests/test_timeannotators.py Make a stab at getting tests to pass when uSec is 0.
Tres Seaver
tseaver at palladion.com
Fri Feb 18 16:46:57 EST 2011
Log message for revision 120428:
Make a stab at getting tests to pass when uSec is 0.
Apparently, this happens a lot on Windows machines; on an OS with
a real timer API, its a one-in-a-million shot. ;)
Changed:
U zope.dublincore/trunk/src/zope/dublincore/tests/test_timeannotators.py
-=-
Modified: zope.dublincore/trunk/src/zope/dublincore/tests/test_timeannotators.py
===================================================================
--- zope.dublincore/trunk/src/zope/dublincore/tests/test_timeannotators.py 2011-02-18 21:36:14 UTC (rev 120427)
+++ zope.dublincore/trunk/src/zope/dublincore/tests/test_timeannotators.py 2011-02-18 21:46:57 UTC (rev 120428)
@@ -20,12 +20,18 @@
import re
datetime_re = (
- '[0-9]{4}, [0-9]{1,2}, [0-9]{1,2}, [0-9]{1,2}, [0-9]{1,2}, [0-9]{1,2}, '
- '[0-9]{1,6}')
+ '[0-9]{4}, ' # YYYY
+ '[0-9]{1,2}, ' # MM
+ '[0-9]{1,2}, ' # DD
+ '[0-9]{1,2}, ' # HH
+ '[0-9]{1,2}, ' # MM
+ '[0-9]{1,2}' # SS
+ '(, [0-9]{1,6})?' # uSec (skipped if 0)
+ )
def test_suite():
return doctest.DocFileSuite(
'timeannotators.txt',
checker=zope.testing.renormalizing.RENormalizing(
[(re.compile(datetime_re), '<DATETIME>')])
- )
\ No newline at end of file
+ )
More information about the checkins
mailing list