Merge branch 'master' into bugfix/fixes-return-url-missing-on-redirect-to-login-page

This commit is contained in:
BinaryAlley authored and GitHub committed 2026-11-01 11:08:40 +02:00
commit 235c2ef9ea
6 files changed
+22 -43

No files matched your search

@@ -449,11 +449,13 @@ public class TranscodingCacheCoordinatorTests : IDisposable
string cacheId = CreateCacheId();
string cachePath = Path.Combine(_cacheRoot, cacheId);
PublishEntry(cacheId, 50, 100);
Thread.Sleep(200);
// The entry must be older than the grace period before the touch, and the touch must still be inside it when the reservation
// runs. A grace period of seconds keeps the second condition true on slow CI runners, where a few hundred milliseconds can pass between the two calls.
Thread.Sleep(2100);
// Act
_sut.Touch(cacheId, TimeSpan.Zero);
bool result = _sut.TryReserve(80, 100, TimeSpan.FromMilliseconds(100), out _);
bool result = _sut.TryReserve(80, 100, TimeSpan.FromSeconds(2), out _);
// Assert
Assert.False(result);
@@ -43,7 +43,8 @@ public class FileHashServiceTests
shouldParallelizeReads: true,
() =>
{
callbackInvocationCount++;
// The callback is invoked concurrently by the parallel reads, so a plain increment could lose a count.
Interlocked.Increment(ref callbackInvocationCount);
return Task.CompletedTask;
},
CancellationToken.None);