[Erp5-report] r43469 jm - /erp5/trunk/products/ERP5Type/tests/testCacheTool.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Fri Feb 18 11:49:40 CET 2011
Author: jm
Date: Fri Feb 18 11:49:40 2011
New Revision: 43469
URL: http://svn.erp5.org?rev=43469&view=rev
Log:
Fix random failures of test_06_CheckCacheExpiration
Modified:
erp5/trunk/products/ERP5Type/tests/testCacheTool.py
Modified: erp5/trunk/products/ERP5Type/tests/testCacheTool.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5Type/tests/testCacheTool.py?rev=43469&r1=43468&r2=43469&view=diff
==============================================================================
--- erp5/trunk/products/ERP5Type/tests/testCacheTool.py [utf8] (original)
+++ erp5/trunk/products/ERP5Type/tests/testCacheTool.py [utf8] Fri Feb 18 11:49:40 2011
@@ -494,7 +494,8 @@ return 'a' * 1024 * 1024 * 25
self.assertTrue(calculation_time < 1.0)
# Wait expiration period then check that value is computed
- time_left_to_wait = (self.cache_duration - calculation_time)
+ # .1 is an additional epsilon delay to work around time precision issues
+ time_left_to_wait = .1 + self.cache_duration
print "\n\tSleep %.2f seconds to wait expiration time" % time_left_to_wait
time.sleep(time_left_to_wait)
More information about the Erp5-report
mailing list