Skip to content

Commit 91f4d57

Browse files
authored
disable multicast tests on AzureLinux (#117694)
1 parent 4ea1713 commit 91f4d57

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/libraries/System.Net.Sockets/tests/FunctionalTests/SocketOptionNameTest.cs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ namespace System.Net.Sockets.Tests
1616
public partial class SocketOptionNameTest
1717
{
1818
private static bool SocketsReuseUnicastPortSupport => Capability.SocketsReuseUnicastPortSupport().HasValue;
19+
// Does not work on Nano and Qemu and AzureLinux has firewall enabled by default
20+
private static readonly bool CanRunMulticastTests = !(PlatformDetection.IsWindowsNanoServer || PlatformDetection.IsWindowsServerCore ||
21+
PlatformDetection.IsAzureLinux || PlatformDetection.IsQemuLinux);
1922

2023
[ConditionalFact(nameof(SocketsReuseUnicastPortSupport))]
2124
public void ReuseUnicastPort_CreateSocketGetOption()
@@ -66,8 +69,7 @@ public void MulticastOption_CreateSocketSetGetOption_GroupAndInterfaceIndex_SetS
6669
}
6770
}
6871

69-
[ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotWindowsNanoNorServerCore))] // Skip on Nano: https://github.com/dotnet/runtime/issues/26286
70-
[ActiveIssue("https://github.com/dotnet/runtime/issues/104547", typeof(PlatformDetection), nameof(PlatformDetection.IsQemuLinux))]
72+
[ConditionalFact(nameof(CanRunMulticastTests))]
7173
[ActiveIssue("https://github.com/dotnet/runtime/issues/113827", typeof(PlatformDetection), nameof(PlatformDetection.IsAppleMobile))]
7274
public async Task MulticastInterface_Set_AnyInterface_Succeeds()
7375
{
@@ -124,10 +126,9 @@ public void MulticastInterface_Set_InvalidIndex_Throws()
124126
}
125127
}
126128

127-
[ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotWindowsNanoNorServerCore))] // Skip on Nano: https://github.com/dotnet/runtime/issues/26286
129+
[ConditionalFact(nameof(CanRunMulticastTests))]
128130
[SkipOnPlatform(TestPlatforms.OSX | TestPlatforms.FreeBSD, "Expected behavior is different on OSX or FreeBSD")]
129131
[ActiveIssue("https://github.com/dotnet/runtime/issues/52124", TestPlatforms.iOS | TestPlatforms.tvOS | TestPlatforms.MacCatalyst)]
130-
[ActiveIssue("https://github.com/dotnet/runtime/issues/104547", typeof(PlatformDetection), nameof(PlatformDetection.IsQemuLinux))]
131132
public async Task MulticastInterface_Set_IPv6_AnyInterface_Succeeds()
132133
{
133134
// On all platforms, index 0 means "any interface"

0 commit comments

Comments
 (0)