tests/ecore_animators: Don't rely on consistent timing

This may break under heavy load so we shouldn't rely on it. Instead make
sure that time only moves forward.

Signed-off-by: Daniel Willmann <d.willmann@samsung.com>
This commit is contained in:
Daniel Willmann 2013-05-17 18:16:09 +01:00
parent 04829b9244
commit d1e38b8535
1 changed files with 1 additions and 8 deletions

View File

@ -10,15 +10,8 @@
static double prev = 0;
static Eina_Bool _anim_cb(void *data, double pos)
{
double interval = *(double *)data;
/* Make sure the intervals are within tolerances
* Ignore first and last step */
if (prev != 0 && pos != 1.0) {
fail_if(pos-prev > interval*1.1);
fail_if(pos-prev < interval*0.9);
}
fail_if(prev >= pos);
prev = pos;
if (pos == 1.0)