Author: lupus
Date: 2007-10-19 11:59:13 -0400 (Fri, 19 Oct 2007)
New Revision: 87834
Modified:
trunk/mcs/class/corlib/Test/System.Threading/TimerTest.cs
Log:
More time-dependent fixing.
Modified: trunk/mcs/class/corlib/Test/System.Threading/TimerTest.cs
===================================================================
--- trunk/mcs/class/corlib/Test/System.Threading/TimerTest.cs 2007-10-19
15:43:06 UTC (rev 87833)
+++ trunk/mcs/class/corlib/Test/System.Threading/TimerTest.cs 2007-10-19
15:59:13 UTC (rev 87834)
@@ -113,7 +113,12 @@
i++;
}
// 1000 * 10 msec = 10,000 msec or 10 sec - if
everything goes well
- Thread.Sleep(12*500);
+ // we add some slack to cope with timing issues caused
by system load etc.
+ for (int i = 0; i < 20; ++i) {
+ if (b.count == 500)
+ break;
+ Thread.Sleep(1000);
+ }
Assert.AreEqual(500,b.count);
}
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches