-
Notifications
You must be signed in to change notification settings - Fork 432
Open
Labels
Customer reportedIndicates issue was opened by customerIndicates issue was opened by customerEnhancementThe issue is a new featureThe issue is a new featureFundamentals
Description
Currently, token lifetime validation is performed by getting the current time from a DateTime ambient context, as seen here.
(I know there's other places where DateTime is used to get the current time, this is just an example)
This leads to flaky, non-deterministic tests, as there's no control of the current time whatsoever.
With the introduction of TimeProvider in .NET 8, there's an out-of-the-box solution for abstracting time.
My proposal here is adopt TimeProvider instead of relying directly on static DateTime class.
SamuelBittmann, MeikelLP and bsdayo
Metadata
Metadata
Assignees
Labels
Customer reportedIndicates issue was opened by customerIndicates issue was opened by customerEnhancementThe issue is a new featureThe issue is a new featureFundamentals