Skip to content

Commit

Permalink
Change Not IsWindows condition to IsLinux on Socket test disable (#94163
Browse files Browse the repository at this point in the history
)

* Fix Not IsWindows to IsLinux on test disable

* Match TelemetryTest behavior with Connect Test

* Change to use connectMethod
  • Loading branch information
liveans authored Oct 31, 2023
1 parent 0a837d3 commit f2e4ddf
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ public async Task Connect_AfterDisconnect_Fails()
[InlineData("[::ffff:1.1.1.1]", true, false)]
public async Task ConnectGetsCanceledByDispose(string addressString, bool useDns, bool owning)
{
if (UsesSync && !PlatformDetection.IsWindows)
if (UsesSync && PlatformDetection.IsLinux)
{
// [ActiveIssue("https://github.com/dotnet/runtime/issues/94149", TestPlatforms.Linux)]
return;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -187,13 +187,18 @@ await listener.RunWithCallbackAsync(e => events.Enqueue((e, e.ActivityId)), asyn
}, connectMethod, useDnsEndPoint.ToString()).Dispose();
}

[ActiveIssue("https://github.com/dotnet/runtime/issues/94149", TestPlatforms.Linux)]
[OuterLoop]
[ConditionalTheory(typeof(RemoteExecutor), nameof(RemoteExecutor.IsSupported))]
[SkipOnPlatform(TestPlatforms.OSX | TestPlatforms.FreeBSD, "Same as Connect.ConnectGetsCanceledByDispose")]
[MemberData(nameof(SocketMethods_WithBools_MemberData))]
public void EventSource_SocketConnectFailure_LogsConnectFailed(string connectMethod, bool useDnsEndPoint)
{
if (connectMethod == "Sync" && PlatformDetection.IsLinux)
{
// [ActiveIssue("https://github.com/dotnet/runtime/issues/94149", TestPlatforms.Linux)]
return;
}

RemoteExecutor.Invoke(async (connectMethod, useDnsEndPointString) =>
{
EndPoint endPoint = await GetRemoteEndPointAsync(useDnsEndPointString, port: 12345);
Expand Down

0 comments on commit f2e4ddf

Please sign in to comment.