Skip to content

Commit 9731032

Browse files
restrict tests to platforms that support threading
1 parent d4a4905 commit 9731032

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/libraries/System.Threading.Tasks/tests/Task/AsyncEnumerableToBlockingEnumerableTests.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ namespace System.Threading.Tasks.Tests
1111
public class AsyncEnumerableToBlockingEnumerableTests
1212
{
1313

14-
[Fact]
14+
[ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsThreadingSupported))]
1515
public static void EmptyAsyncEnumerable()
1616
{
1717
var source = new InstrumentedAsyncEnumerable<int>(CreateSourceEnumerable());
@@ -34,7 +34,7 @@ static async IAsyncEnumerable<int> CreateSourceEnumerable()
3434
}
3535
}
3636

37-
[Fact]
37+
[ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsThreadingSupported))]
3838
public static void SimpleAsyncEnumerable()
3939
{
4040
var source = new InstrumentedAsyncEnumerable<int>(CreateSourceEnumerable());
@@ -69,7 +69,7 @@ static async IAsyncEnumerable<int> CreateSourceEnumerable()
6969
}
7070
}
7171

72-
[Fact]
72+
[ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsThreadingSupported))]
7373
public static void AsyncEnumerableWithDelays()
7474
{
7575
var source = new InstrumentedAsyncEnumerable<int>(CreateSourceEnumerable());
@@ -103,7 +103,7 @@ static async IAsyncEnumerable<int> CreateSourceEnumerable()
103103
}
104104
}
105105

106-
[Fact]
106+
[ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsThreadingSupported))]
107107
public static void AsyncEnumerableWithException()
108108
{
109109
var source = new InstrumentedAsyncEnumerable<int>(CreateSourceEnumerable());
@@ -131,7 +131,7 @@ static async IAsyncEnumerable<int> CreateSourceEnumerable()
131131
}
132132
}
133133

134-
[Fact]
134+
[ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsThreadingSupported))]
135135
public static void AsyncEnumerableWithCancellation()
136136
{
137137
var source = new InstrumentedAsyncEnumerable<string>(CreateSourceEnumerable());

0 commit comments

Comments
 (0)