Dotnet, Development, C Sharp Programming, Csharp, Microsoft.
to set a specific behaviour in your tests, allowing you to easily mock the TimeProvider. To use it, you need to install the package Microsoft.Extensions.Time.Testing. With this class, you can for example, make use of the SetUtcMethod, to configure the time you want to return in your test: [Fact]