What is the minimum time you need to Thread.Sleep( ) to ensure DateTime.Now differs ?
Given a DateTime has a Ticks property you could argue the following would suffice:
Thread.Sleep(TimeSpan.FromTicks(1));
which would be fine but does this guarantee subsequent calls to DateTime.Now are not equal?
UPDATE: Appears DateTime precision is hardware dependent so instead I am going to use the following method:
public static void SleepUntilDateTimeChanges()
{
DateTime now = DateTime.Now;
while(now == DateTime.Now)
Thread.Sleep(TimeSpan.FromMilliseconds(1));
}