Example #1
0
        internal void FreezeTimeNow_WithStubSystemClock_ReturnsExpectedTime()
        {
            // Arrange
            var stubClock = new TestClock();

            // Act
            stubClock.FreezeTimeNow();
            var result1 = stubClock.TimeNow();

            Task.Delay(100).Wait();
            var result2 = stubClock.TimeNow();

            // Assert
            Assert.Equal(result1, result2);
        }