This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients jcea, skrah, vstinner
Date 2014-01-23.10:53:01
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1390474381.79.0.751112290109.issue20336@psf.upfronthosting.co.za>
In-reply-to
Content
Tests failing because of timings is really annoying. It would be nice to add something in test.support to configure timings. A function can maybe wait until the system load is lower than a threshold, or we should add a parameter to configure a tolerance between the perfect timing and the expected timing.

The tolerance can be a simple factor, a floating point number >= 1.0.

For example, replace:
    0.09 <= t1-t0 <= 0.9, t1-t0
with
    0.1 - 0.01 * factor <= t1-t0 <= 0.1 + 0.8 * factor
or a new test function:
    check_timing(t1-t0, 0.1, 0.01, 0.8)
History
Date User Action Args
2014-01-23 10:53:01vstinnersetrecipients: + vstinner, jcea, skrah
2014-01-23 10:53:01vstinnersetmessageid: <1390474381.79.0.751112290109.issue20336@psf.upfronthosting.co.za>
2014-01-23 10:53:01vstinnerlinkissue20336 messages
2014-01-23 10:53:01vstinnercreate