Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

disable test parallelization for http3 #56413

Merged
merged 1 commit into from
Jul 30, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3143,20 +3143,23 @@ public SocketsHttpHandler_HttpClientHandler_Cancellation_Test_Http2(ITestOutputH
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMsQuicSupported))]
[Collection("NoParallelTests")]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit:

Suggested change
[Collection("NoParallelTests")]
[Collection(nameof(NoParallelTests))]

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Technically, this is name of the collection, not name of the class right?

[CollectionDefinition("NoParallelTests", DisableParallelization = true)]

It so happen we name them the same.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, but it still helps IMO by binding the string constant to a symbol name in the C# compilation. (Harder to make a typo assuming we may have more of these.)

public sealed class SocketsHttpHandlerTest_Http3_MsQuic : HttpClientHandlerTest_Http3
{
public SocketsHttpHandlerTest_Http3_MsQuic(ITestOutputHelper output) : base(output) { }
protected override QuicImplementationProvider UseQuicImplementationProvider => QuicImplementationProviders.MsQuic;
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMockQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandlerTest_Http3_Mock : HttpClientHandlerTest_Http3
{
public SocketsHttpHandlerTest_Http3_Mock(ITestOutputHelper output) : base(output) { }
protected override QuicImplementationProvider UseQuicImplementationProvider => QuicImplementationProviders.Mock;
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMsQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandlerTest_HttpClientHandlerTest_Http3_MsQuic : HttpClientHandlerTest
{
public SocketsHttpHandlerTest_HttpClientHandlerTest_Http3_MsQuic(ITestOutputHelper output) : base(output) { }
Expand All @@ -3165,6 +3168,7 @@ public SocketsHttpHandlerTest_HttpClientHandlerTest_Http3_MsQuic(ITestOutputHelp
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMockQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandlerTest_HttpClientHandlerTest_Http3_Mock : HttpClientHandlerTest
{
public SocketsHttpHandlerTest_HttpClientHandlerTest_Http3_Mock(ITestOutputHelper output) : base(output) { }
Expand All @@ -3174,6 +3178,7 @@ public SocketsHttpHandlerTest_HttpClientHandlerTest_Http3_Mock(ITestOutputHelper

[ActiveIssue("https://github.com/dotnet/runtime/issues/53093")]
[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMsQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandlerTest_Cookies_Http3_MsQuic : HttpClientHandlerTest_Cookies
{
public SocketsHttpHandlerTest_Cookies_Http3_MsQuic(ITestOutputHelper output) : base(output) { }
Expand All @@ -3183,6 +3188,7 @@ public SocketsHttpHandlerTest_Cookies_Http3_MsQuic(ITestOutputHelper output) : b

[ActiveIssue("https://github.com/dotnet/runtime/issues/53093")]
[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMockQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandlerTest_Cookies_Http3_Mock : HttpClientHandlerTest_Cookies
{
public SocketsHttpHandlerTest_Cookies_Http3_Mock(ITestOutputHelper output) : base(output) { }
Expand All @@ -3191,6 +3197,7 @@ public SocketsHttpHandlerTest_Cookies_Http3_Mock(ITestOutputHelper output) : bas
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMsQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandlerTest_HttpClientHandlerTest_Headers_Http3_MsQuic : HttpClientHandlerTest_Headers
{
public SocketsHttpHandlerTest_HttpClientHandlerTest_Headers_Http3_MsQuic(ITestOutputHelper output) : base(output) { }
Expand All @@ -3199,6 +3206,7 @@ public SocketsHttpHandlerTest_HttpClientHandlerTest_Headers_Http3_MsQuic(ITestOu
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMockQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandlerTest_HttpClientHandlerTest_Headers_Http3_Mock : HttpClientHandlerTest_Headers
{
public SocketsHttpHandlerTest_HttpClientHandlerTest_Headers_Http3_Mock(ITestOutputHelper output) : base(output) { }
Expand All @@ -3207,6 +3215,7 @@ public SocketsHttpHandlerTest_HttpClientHandlerTest_Headers_Http3_Mock(ITestOutp
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMsQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandler_HttpClientHandler_Cancellation_Test_Http3_MsQuic : SocketsHttpHandler_Cancellation_Test
{
public SocketsHttpHandler_HttpClientHandler_Cancellation_Test_Http3_MsQuic(ITestOutputHelper output) : base(output) { }
Expand All @@ -3215,6 +3224,7 @@ public SocketsHttpHandler_HttpClientHandler_Cancellation_Test_Http3_MsQuic(ITest
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMockQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandler_HttpClientHandler_Cancellation_Test_Http3_Mock : SocketsHttpHandler_Cancellation_Test
{
public SocketsHttpHandler_HttpClientHandler_Cancellation_Test_Http3_Mock(ITestOutputHelper output) : base(output) { }
Expand All @@ -3223,6 +3233,7 @@ public SocketsHttpHandler_HttpClientHandler_Cancellation_Test_Http3_Mock(ITestOu
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMsQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandler_HttpClientHandler_AltSvc_Test_Http3_MsQuic : HttpClientHandler_AltSvc_Test
{
public SocketsHttpHandler_HttpClientHandler_AltSvc_Test_Http3_MsQuic(ITestOutputHelper output) : base(output) { }
Expand All @@ -3231,6 +3242,7 @@ public SocketsHttpHandler_HttpClientHandler_AltSvc_Test_Http3_MsQuic(ITestOutput
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMockQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandler_HttpClientHandler_AltSvc_Test_Http3_Mock : HttpClientHandler_AltSvc_Test
{
public SocketsHttpHandler_HttpClientHandler_AltSvc_Test_Http3_Mock(ITestOutputHelper output) : base(output) { }
Expand All @@ -3239,6 +3251,7 @@ public SocketsHttpHandler_HttpClientHandler_AltSvc_Test_Http3_Mock(ITestOutputHe
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMsQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandler_HttpClientHandler_Finalization_Http3_MsQuic : HttpClientHandler_Finalization_Test
{
public SocketsHttpHandler_HttpClientHandler_Finalization_Http3_MsQuic(ITestOutputHelper output) : base(output) { }
Expand All @@ -3247,13 +3260,18 @@ public SocketsHttpHandler_HttpClientHandler_Finalization_Http3_MsQuic(ITestOutpu
}

[ConditionalClass(typeof(HttpClientHandlerTestBase), nameof(IsMockQuicSupported))]
[Collection("NoParallelTests")]
public sealed class SocketsHttpHandler_HttpClientHandler_Finalization_Http3_Mock : HttpClientHandler_Finalization_Test
{
public SocketsHttpHandler_HttpClientHandler_Finalization_Http3_Mock(ITestOutputHelper output) : base(output) { }
protected override Version UseVersion => HttpVersion.Version30;
protected override QuicImplementationProvider UseQuicImplementationProvider => QuicImplementationProviders.Mock;
}

// Define test collection for tests to avoid all other tests.
[CollectionDefinition("NoParallelTests", DisableParallelization = true)]
public partial class NoParallelTests { }

[ConditionalClass(typeof(PlatformDetection), nameof(PlatformDetection.IsNotBrowser))]
public abstract class SocketsHttpHandler_RequestValidationTest
{
Expand Down