We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
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 tests, as there's no control of the current time whatsoever, rendering tests not deterministic.
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.
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
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 tests, as there's no control of the current time whatsoever, rendering tests not deterministic.
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.
The text was updated successfully, but these errors were encountered: