diff --git a/ProxyForge.Tests/ProxyEncoderTests.cs b/ProxyForge.Tests/ProxyEncoderTests.cs index 2366f4f..23f1886 100644 --- a/ProxyForge.Tests/ProxyEncoderTests.cs +++ b/ProxyForge.Tests/ProxyEncoderTests.cs @@ -7,6 +7,7 @@ using ProxyForge.Sources; namespace ProxyForge.Tests; +[Collection("Direct2D")] public sealed class ProxyEncoderTests { const string SoftwareEncoder = FFmpegArguments.SoftwareVideoEncoder; diff --git a/ProxyForge.Tests/ProxyFrameRendererTests.cs b/ProxyForge.Tests/ProxyFrameRendererTests.cs index 88cdcca..098fee5 100644 --- a/ProxyForge.Tests/ProxyFrameRendererTests.cs +++ b/ProxyForge.Tests/ProxyFrameRendererTests.cs @@ -3,6 +3,7 @@ using YukkuriMovieMaker.Commons; namespace ProxyForge.Tests; +[Collection("Direct2D")] public sealed class ProxyFrameRendererTests { static (byte Blue, byte Green, byte Red, byte Alpha) Bgra(int blue, int green, int red, int alpha) diff --git a/ProxyForge.Tests/ProxySourceProviderTests.cs b/ProxyForge.Tests/ProxySourceProviderTests.cs index 1149d86..4ea73e6 100644 --- a/ProxyForge.Tests/ProxySourceProviderTests.cs +++ b/ProxyForge.Tests/ProxySourceProviderTests.cs @@ -7,6 +7,7 @@ using YukkuriMovieMaker.Commons; namespace ProxyForge.Tests; +[Collection("Direct2D")] public sealed class ProxySourceProviderTests : IDisposable { readonly string root = Path.Combine(Path.GetTempPath(), "ProxyForgeTests", Guid.NewGuid().ToString("N")); @@ -278,7 +279,7 @@ public sealed class ProxySourceProviderTests : IDisposable Assert.False(proxy.IsProxy); release.SetResult(); await pending.WhenIdleAsync(); - for (var attempt = 0; attempt < 200 && !proxy.IsProxy; attempt++) + for (var attempt = 0; attempt < 500 && !proxy.IsProxy; attempt++) { proxy.Update(TimeSpan.Zero); await Task.Delay(10, TestContext.Current.CancellationToken); @@ -306,7 +307,7 @@ public sealed class ProxySourceProviderTests : IDisposable using var source = CreateProvider().Create(context, path); var proxy = Assert.IsType(source); await queue.WhenIdleAsync(); - for (var attempt = 0; attempt < 200 && !proxy.IsProxy; attempt++) + for (var attempt = 0; attempt < 500 && !proxy.IsProxy; attempt++) { proxy.Update(TimeSpan.FromSeconds(1)); await Task.Delay(10, TestContext.Current.CancellationToken); diff --git a/ProxyForge.Tests/ProxyUpgradeLoaderTests.cs b/ProxyForge.Tests/ProxyUpgradeLoaderTests.cs index 19136ac..25af341 100644 --- a/ProxyForge.Tests/ProxyUpgradeLoaderTests.cs +++ b/ProxyForge.Tests/ProxyUpgradeLoaderTests.cs @@ -7,6 +7,7 @@ using YukkuriMovieMaker.Commons; namespace ProxyForge.Tests; +[Collection("Direct2D")] public sealed class ProxyUpgradeLoaderTests : IDisposable { readonly string root = Path.Combine(Path.GetTempPath(), "ProxyForgeTests", Guid.NewGuid().ToString("N")); diff --git a/ProxyForge.Tests/ProxyVideoSourceTests.cs b/ProxyForge.Tests/ProxyVideoSourceTests.cs index 6b64e19..12f6ec8 100644 --- a/ProxyForge.Tests/ProxyVideoSourceTests.cs +++ b/ProxyForge.Tests/ProxyVideoSourceTests.cs @@ -6,6 +6,7 @@ using YukkuriMovieMaker.Commons; namespace ProxyForge.Tests; +[Collection("Direct2D")] public sealed class ProxyVideoSourceTests : IDisposable { readonly GraphicsDevices devices = new();