public void SetSystemTime() { var sntpClock = new SntpClock(); var now = sntpClock.UtcNow; SystemClock.Win32.SetUtc(now); }
public void GetUtcNowDefault() { var clock = new SntpClock(); var difference = DateTime.UtcNow - clock.UtcNow; Assert.AreEqual(0, difference.TotalMilliseconds, 1000 * 60, "System Utc clock difference with NTP clock is too large: " + difference); }