118 references to FakeTimeProvider
InMemory.FunctionalTests (3)
Http2\Http2TestBase.cs (1)
122private readonly FakeTimeProvider _timeProvider = new();
RequestBodyTimeoutTests.cs (1)
107var timeProvider = new FakeTimeProvider();
src\Servers\Kestrel\shared\test\TestServiceContext.cs (1)
55FakeTimeProvider = new FakeTimeProvider();
Microsoft.AspNetCore.Authentication.Test (2)
CookieTests.cs (1)
25private readonly FakeTimeProvider _timeProvider = new();
SharedAuthenticationTests.cs (1)
15protected FakeTimeProvider TimeProvider { get; } = new();
Microsoft.AspNetCore.Identity.FunctionalTests (2)
MapIdentityApiTests.cs (2)
163var clock = new FakeTimeProvider(); 323var clock = new FakeTimeProvider();
Microsoft.AspNetCore.Identity.InMemory.Test (5)
FunctionalTest.cs (5)
71var timeProvider = new FakeTimeProvider(); 119var timeProvider = new FakeTimeProvider(); 168var timeProvider = new FakeTimeProvider(); 221var timeProvider = new FakeTimeProvider(); 250var timeProvider = new FakeTimeProvider();
Microsoft.AspNetCore.Identity.Test (1)
SecurityStampValidatorTest.cs (1)
275var timeProvider = new FakeTimeProvider();
Microsoft.AspNetCore.OutputCaching.Tests (5)
OutputCacheMiddlewareTests.cs (5)
370var timeProvider = new FakeTimeProvider(); 386var timeProvider = new FakeTimeProvider(); 423var timeProvider = new FakeTimeProvider(); 446var timeProvider = new FakeTimeProvider(); 472var timeProvider = new FakeTimeProvider();
Microsoft.AspNetCore.ResponseCaching.Tests (5)
ResponseCachingMiddlewareTests.cs (5)
361var timeProvider = new FakeTimeProvider(); 377var timeProvider = new FakeTimeProvider(); 447var timeProvider = new FakeTimeProvider(); 470var timeProvider = new FakeTimeProvider(); 495var timeProvider = new FakeTimeProvider();
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (12)
DateHeaderValueManagerTests.cs (4)
25var timeProvider = new FakeTimeProvider(); 37var timeProvider = new FakeTimeProvider(); 56var timeProvider = new FakeTimeProvider(); 85var timeProvider = new FakeTimeProvider();
HeartbeatTests.cs (4)
27var timeProvider = new FakeTimeProvider(); 103var timeProvider = new FakeTimeProvider(); 146var timeProvider = new FakeTimeProvider(); 185var timeProvider = new FakeTimeProvider();
KestrelServerTests.cs (1)
715var timeProvider = new FakeTimeProvider();
src\Servers\Kestrel\shared\test\TestServiceContext.cs (1)
55FakeTimeProvider = new FakeTimeProvider();
StartLineTests.cs (1)
523var timeProvider = new FakeTimeProvider();
TimeoutControlTests.cs (1)
20_timeProvider = new FakeTimeProvider();
Microsoft.AspNetCore.Server.Kestrel.Microbenchmarks (1)
Http3\Http3ConnectionBenchmarkBase.cs (1)
44var timeProvider = new FakeTimeProvider();
Microsoft.AspNetCore.Server.Kestrel.Transport.Quic.Tests (1)
QuicConnectionContextTests.cs (1)
508var timeProvider = new FakeTimeProvider();
Microsoft.AspNetCore.SignalR.Tests (7)
HubConnectionHandlerTests.cs (5)
2740var timeProvider = new FakeTimeProvider(); 2802var timeProvider = new FakeTimeProvider(); 2838var timeProvider = new FakeTimeProvider(); 2865var timeProvider = new FakeTimeProvider(); 2901var timeProvider = new FakeTimeProvider();
Internal\MessageBufferTests.cs (2)
369var timeProvider = new FakeTimeProvider(); 449var timeProvider = new FakeTimeProvider();
Microsoft.Extensions.Diagnostics.Probes.Tests (1)
TcpEndpointProbesServiceTests.cs (1)
31var timeProvider = new FakeTimeProvider();
Microsoft.Extensions.Diagnostics.ResourceMonitoring.Tests (25)
CalculatorTests.cs (2)
19totalTimeSinceStart: TimeSpan.FromTicks(new FakeTimeProvider().GetUtcNow().Ticks), 122totalTimeSinceStart: TimeSpan.FromTicks(new FakeTimeProvider().GetUtcNow().Ticks),
Helpers\DummyProvider.cs (1)
15public static readonly FakeTimeProvider SnapshotTimeClock = new();
Providers\ConditionallyFaultProvider.cs (1)
35TimeSpan.FromTicks(new FakeTimeProvider().GetUtcNow().Ticks),
Providers\FakeProvider.cs (1)
12TimeSpan.FromTicks(new FakeTimeProvider().GetUtcNow().Ticks),
Providers\FaultProvider.cs (1)
11private readonly FakeTimeProvider _clock = new();
ResourceMonitoringServiceTests.cs (6)
31private static readonly FakeTimeProvider _clock = new(); 229var clock = new FakeTimeProvider(); 306var clock = new FakeTimeProvider(); 354var clock = new FakeTimeProvider(); 387var clock = new FakeTimeProvider(); 494var clock = new FakeTimeProvider();
SnapshotTests.cs (3)
15var time = new FakeTimeProvider(); 30=> new Snapshot(new FakeTimeProvider(), TimeSpan.MinValue, TimeSpan.FromSeconds(1), 1000)); 37=> new Snapshot(new FakeTimeProvider(), TimeSpan.Zero, TimeSpan.MinValue, 1000));
Windows\WindowsContainerSnapshotProviderTests.cs (8)
99new FakeTimeProvider(), 122new FakeTimeProvider(), 146new FakeTimeProvider(), 179new FakeTimeProvider(), 212var fakeClock = new FakeTimeProvider(); 275var fakeClock = new FakeTimeProvider(); 320new FakeTimeProvider(), 341new FakeTimeProvider(),
Windows\WindowsSnapshotProviderTests.cs (2)
77var fakeClock = new FakeTimeProvider(); 112var fakeClock = new FakeTimeProvider();
Microsoft.Extensions.Diagnostics.Testing.Tests (4)
Logging\FakeLogCollectorTests.cs (2)
31var timeProvider = new FakeTimeProvider(); 73var timeProvider = new FakeTimeProvider();
Logging\FakeLoggerTests.cs (2)
21var timeProvider = new FakeTimeProvider(); 248var timeProvider = new FakeTimeProvider();
Microsoft.Extensions.Hosting.Testing.Tests (6)
FakeHostTests.cs (4)
75var timeProvider = new FakeTimeProvider(); 134var timeProvider = new FakeTimeProvider(); 166var sut = new FakeHost(hostMock.Object, new FakeHostOptions()) { TimeProvider = new FakeTimeProvider() }; 179var sut = new FakeHost(hostMock.Object, new FakeHostOptions()) { TimeProvider = new FakeTimeProvider() };
HostTerminatorServiceTests.cs (2)
23using var sut = new HostTerminatorService(hostMock.Object, options, logger) { TimeProvider = new FakeTimeProvider() }; 33var timeProvider = new FakeTimeProvider();
Microsoft.Extensions.Http.Resilience.Tests (2)
Internal\RetryAfterHelperTests.cs (2)
42var timeProvider = new FakeTimeProvider(); 56var timeProvider = new FakeTimeProvider();
Microsoft.Extensions.ServiceDiscovery.Dns.Tests (1)
DnsServiceEndpointResolverTests.cs (1)
16var timeProvider = new FakeTimeProvider();
Microsoft.Extensions.TimeProvider.Testing.Tests (33)
FakeTimeProviderTests.cs (19)
18var timeProvider = new FakeTimeProvider(); 84var timeProvider = new FakeTimeProvider(); 93var timeProvider = new FakeTimeProvider(); 154var timeProvider = new FakeTimeProvider(); 163var tp = new FakeTimeProvider(); 190var tp = new FakeTimeProvider(); 228var timeProvider = new FakeTimeProvider(); 238var timeProvider = new FakeTimeProvider(); 252var timeProvider = new FakeTimeProvider(); 268var timeProvider = new FakeTimeProvider(); 280var timeProvider = new FakeTimeProvider(); 307var timeProvider = new FakeTimeProvider(); 326var timeProvider = new FakeTimeProvider(); 344var timeProvider = new FakeTimeProvider(); 376var timeProvider = new FakeTimeProvider(); 386var timeProvider = new FakeTimeProvider 401var timeProvider = new FakeTimeProvider(); 418var provider = new FakeTimeProvider { AutoAdvanceAmount = TimeSpan.FromSeconds(2) }; 449var provider = new FakeTimeProvider();
TimerTests.cs (14)
24var timeProvider = new FakeTimeProvider(); 46var timeProvider = new FakeTimeProvider(); 68var timeProvider = new FakeTimeProvider(); 90var timeProvider = new FakeTimeProvider(); 112var timeProvider = new FakeTimeProvider(); 138var fakeTimeProvider = new FakeTimeProvider(); 153var fakeTimeProvider = new FakeTimeProvider(); 168using var t = new Timer(new FakeTimeProvider(), new TimerCallback(EmptyTimerTarget), null); 180using var t = new Timer(new FakeTimeProvider(), new TimerCallback(EmptyTimerTarget), null); 192var t = new Timer(new FakeTimeProvider(), new TimerCallback(EmptyTimerTarget), null); 203var t = new Timer(new FakeTimeProvider(), new TimerCallback(EmptyTimerTarget), null); 217var timeProvider = new FakeTimeProvider(); 326var timeProvider = new FakeTimeProvider(); 357var timeProvider = new FakeTimeProvider();
Sockets.BindTests (1)
src\Servers\Kestrel\shared\test\TestServiceContext.cs (1)
55FakeTimeProvider = new FakeTimeProvider();
Sockets.FunctionalTests (1)
src\Servers\Kestrel\shared\test\TestServiceContext.cs (1)
55FakeTimeProvider = new FakeTimeProvider();