Re-enable tests for Sys.RT.Caching #118551
Open
+51
−19
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request updates the
System.Runtime.Caching
test suite to improve coverage and maintainability. The main changes include removing obsolete or restrictive test annotations, refactoring test helpers for better isolation, and adding a new test to verify cache item expiration behavior when file dependencies change.Test coverage and reliability improvements:
[OuterLoop]
testReasonable_Delay
inHostFileChangeMonitorTest.cs
to verify that cache items expire promptly when a monitored file changes.SetupMonitoring
helper to accept a unique ID, ensuring test file isolation and reducing interference between tests. [1] [2]Test annotation and platform restriction cleanup:
[ActiveIssue]
,[PlatformSpecific]
, and[SkipOnPlatform]
annotations from several tests in bothHostFileChangeMonitorTest.cs
andMemoryCacheTest.cs
, enabling broader test execution across platforms and configurations. [1] [2] [3] [4] [5] [6] [7]General code and import maintenance:
HostFileChangeMonitorTest.cs
to remove unnecessary imports and improve code clarity.