mirror of
https://github.com/ICDSystems/ICD.Common.Utils.git
synced 2026-02-16 13:15:07 +00:00
Additional test
This commit is contained in:
@@ -13,14 +13,16 @@ namespace ICD.Common.Utils.Tests
|
|||||||
Assert.IsTrue(ThreadingUtils.Wait(() => true, 100));
|
Assert.IsTrue(ThreadingUtils.Wait(() => true, 100));
|
||||||
|
|
||||||
bool complete = false;
|
bool complete = false;
|
||||||
|
DateTime time = IcdEnvironment.GetLocalTime();
|
||||||
|
|
||||||
ThreadingUtils.SafeInvoke(() =>
|
ThreadingUtils.SafeInvoke(() =>
|
||||||
{
|
{
|
||||||
ThreadingUtils.Sleep(50);
|
ThreadingUtils.Sleep(100);
|
||||||
complete = true;
|
complete = true;
|
||||||
});
|
});
|
||||||
|
|
||||||
Assert.IsTrue(ThreadingUtils.Wait(() => complete, 200));
|
Assert.IsTrue(ThreadingUtils.Wait(() => complete, 200));
|
||||||
|
Assert.AreEqual(100, (IcdEnvironment.GetLocalTime() - time).TotalMilliseconds, 20);
|
||||||
}
|
}
|
||||||
|
|
||||||
[Test]
|
[Test]
|
||||||
|
|||||||
Reference in New Issue
Block a user