Skip to content

Commit

Permalink
Use Microsoft.Extensions.TimeProvider.Testing
Browse files Browse the repository at this point in the history
Use the new `Microsoft.Extensions.TimeProvider.Testing` package and remove custom test stub.
  • Loading branch information
martincostello committed Aug 9, 2023
1 parent 9887670 commit f0b3417
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 376 deletions.
1 change: 1 addition & 0 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
<PackageVersion Include="Microsoft.Extensions.Logging.Console" Version="$(MicrosoftExtensionsVersion)" />
<PackageVersion Include="Microsoft.Extensions.Options" Version="$(MicrosoftExtensionsVersion)" />
<PackageVersion Include="Microsoft.Extensions.Options.ConfigurationExtensions" Version="$(MicrosoftExtensionsVersion)" />
<PackageVersion Include="Microsoft.Extensions.TimeProvider.Testing" Version="8.0.0-preview.7.23407.5" />
<PackageVersion Include="Microsoft.NET.Test.Sdk" Version="17.6.3" />
<PackageVersion Include="Microsoft.SourceLink.GitHub" Version="1.1.1" />
<PackageVersion Include="MinVer" Version="4.3.0" />
Expand Down
375 changes: 0 additions & 375 deletions test/Polly.Core.Tests/Helpers/FakeTimeProvider.cs

This file was deleted.

4 changes: 3 additions & 1 deletion test/Polly.Core.Tests/Polly.Core.Tests.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,14 @@
<Nullable>enable</Nullable>
<!-- TODO Change this back to 100 once we find the mysterious flaky missing branch/line -->
<Threshold>99.75</Threshold>
<NoWarn>$(NoWarn);SA1600;SA1204;SA1602;S6608</NoWarn>
<NoWarn>$(NoWarn);SA1600;SA1204;SA1602;S6608;EXTEXP0004</NoWarn>
<Include>[Polly.Core]*</Include>
<SuppressTfmSupportBuildWarnings>true</SuppressTfmSupportBuildWarnings>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Microsoft.Bcl.TimeProvider"/>
<PackageReference Include="Microsoft.Extensions.TimeProvider.Testing" />
<PackageReference Include="Polly.Contrib.WaitAndRetry" />
</ItemGroup>

Expand Down

0 comments on commit f0b3417

Please sign in to comment.