From 1ddf6e0d562f855fbdb04888674264ebf3bdea98 Mon Sep 17 00:00:00 2001 From: Meta Vens Date: Tue, 29 Sep 2026 04:17:31 +0200 Subject: [PATCH] Mark the three share-mode tests Windows-only They hold a FileShare.Read handle and expect a delete or replace to fail; Linux unlink and rename ignore open handles, so they can never pass there and showed as three standing failures. [Platform("Win")] reports them skipped with a reason on Linux and keeps them running on Windows. No Linux failure injection exists: the store names its temp file with a fresh GUID and the suite is likely root in the verify container, so read-only directories do not fail. Co-Authored-By: Claude Sonnet 5 --- tests/GameCult.Caching.Tests/BackingStoreTests.cs | 1 + tests/GameCult.Caching.Tests/DirectoryStoreDurabilityTests.cs | 1 + tests/GameCult.Caching.Tests/StoreRoutingTests.cs | 1 + 3 files changed, 3 insertions(+) diff --git a/tests/GameCult.Caching.Tests/BackingStoreTests.cs b/tests/GameCult.Caching.Tests/BackingStoreTests.cs index 86613c52..7e88c283 100644 --- a/tests/GameCult.Caching.Tests/BackingStoreTests.cs +++ b/tests/GameCult.Caching.Tests/BackingStoreTests.cs @@ -707,6 +707,7 @@ namespace GameCult.Caching.Tests } [Test] + [Platform("Win", Reason = "Holds an open FileShare.Read handle and expects a delete or replace to fail; Linux unlink and rename ignore open handles.")] public async Task DirectoryMessagePackBackingStore_Deletion_Commits_While_Locked_Old_Page_Remains_An_Orphan() { var filePath = Path.Combine(Path.GetTempPath(), $"cultlib-tests-{Guid.NewGuid():N}.cc"); diff --git a/tests/GameCult.Caching.Tests/DirectoryStoreDurabilityTests.cs b/tests/GameCult.Caching.Tests/DirectoryStoreDurabilityTests.cs index 41ef46ad..840110bc 100644 --- a/tests/GameCult.Caching.Tests/DirectoryStoreDurabilityTests.cs +++ b/tests/GameCult.Caching.Tests/DirectoryStoreDurabilityTests.cs @@ -37,6 +37,7 @@ namespace GameCult.Caching.Tests } [Test] + [Platform("Win", Reason = "Holds an open FileShare.Read handle and expects a delete or replace to fail; Linux unlink and rename ignore open handles.")] public async Task FailedManifestReplaceKeepsPreviousGeneration() { using var cache = Open(out _); diff --git a/tests/GameCult.Caching.Tests/StoreRoutingTests.cs b/tests/GameCult.Caching.Tests/StoreRoutingTests.cs index fc99f01f..af7e7da7 100644 --- a/tests/GameCult.Caching.Tests/StoreRoutingTests.cs +++ b/tests/GameCult.Caching.Tests/StoreRoutingTests.cs @@ -439,6 +439,7 @@ namespace GameCult.Caching.Tests } [Test] + [Platform("Win", Reason = "Holds an open FileShare.Read handle and expects a delete or replace to fail; Linux unlink and rename ignore open handles.")] public void BatchIsAllOrNothingOnStoreFailure() { var registry = Registry();