2 using System
.Threading
;
3 using System
.Diagnostics
;
9 public static int Main (String
[] args
) {
10 return TestDriver
.RunTests (typeof (Tests
), args
);
13 public static int test_0_time_drift () {
14 // Test the Thread.Sleep () is able to deal with time drifting due to interrupts
15 Thread t
= new Thread (delegate () {
23 var sw
= Stopwatch
.StartNew ();
27 if (sw
.ElapsedMilliseconds
> 2000) {
28 Console
.WriteLine (sw
.ElapsedMilliseconds
);