diff --git a/src/libraries/Common/tests/StreamConformanceTests/System/IO/StreamConformanceTests.cs b/src/libraries/Common/tests/StreamConformanceTests/System/IO/StreamConformanceTests.cs index 242a2099f0cab..c36ce7c6feb0a 100644 --- a/src/libraries/Common/tests/StreamConformanceTests/System/IO/StreamConformanceTests.cs +++ b/src/libraries/Common/tests/StreamConformanceTests/System/IO/StreamConformanceTests.cs @@ -1742,7 +1742,8 @@ from writeSize in new[] { 10 * 1024 * 1024 } from startWithFlush in new[] { false, true } select new object[] { mode, writeSize, startWithFlush }; - [OuterLoop] + [OuterLoop("May take several seconds", ~TestPlatforms.Browser)] + [SkipOnPlatform(TestPlatforms.Browser, "Not supported on browser")] [Theory] [MemberData(nameof(ReadWrite_Success_Large_MemberData))] public virtual async Task ReadWrite_Success_Large(ReadWriteMode mode, int writeSize, bool startWithFlush) => @@ -2438,7 +2439,8 @@ public static IEnumerable CopyToAsync_AllDataCopied_MemberData() => from useAsync in new bool[] { true, false } select new object[] { byteCount, useAsync }; - [OuterLoop] + [OuterLoop("May take several seconds", ~TestPlatforms.Browser)] + [SkipOnPlatform(TestPlatforms.Browser, "Not supported on browser")] [Theory] [InlineData(false)] [InlineData(true)] diff --git a/src/libraries/Common/tests/System/Security/Cryptography/AlgorithmImplementations/DSA/DSAXml.cs b/src/libraries/Common/tests/System/Security/Cryptography/AlgorithmImplementations/DSA/DSAXml.cs index 9a959df1ada4f..69de7580f62e6 100644 --- a/src/libraries/Common/tests/System/Security/Cryptography/AlgorithmImplementations/DSA/DSAXml.cs +++ b/src/libraries/Common/tests/System/Security/Cryptography/AlgorithmImplementations/DSA/DSAXml.cs @@ -415,7 +415,7 @@ public static void TestWriteDeficientXParameters(bool includePrivateParameters) } [ConditionalFact(typeof(DSAFactory), nameof(DSAFactory.SupportsKeyGeneration))] - [OuterLoop("DSA key generation is very slow")] + [OuterLoop("DSA key generation is very slow", ~TestPlatforms.Browser)] public static void FromToXml() { using (DSA dsa = DSAFactory.Create()) diff --git a/src/libraries/System.Console/tests/WindowAndCursorProps.cs b/src/libraries/System.Console/tests/WindowAndCursorProps.cs index c54fa87f0e361..3f70f02019d6c 100644 --- a/src/libraries/System.Console/tests/WindowAndCursorProps.cs +++ b/src/libraries/System.Console/tests/WindowAndCursorProps.cs @@ -277,7 +277,7 @@ public static void Beep_Invoke_Success() } [Fact] - [OuterLoop] // makes noise, not very inner-loop friendly + [OuterLoop("makes noise, not very inner-loop friendly", ~TestPlatforms.Browser)] [PlatformSpecific(TestPlatforms.Windows)] public static void BeepWithFrequency_Invoke_Success() { diff --git a/src/libraries/System.Linq.Parallel/tests/DegreeOfParallelismTests.cs b/src/libraries/System.Linq.Parallel/tests/DegreeOfParallelismTests.cs index 69c4bb6933ee4..95404c7a3199f 100644 --- a/src/libraries/System.Linq.Parallel/tests/DegreeOfParallelismTests.cs +++ b/src/libraries/System.Linq.Parallel/tests/DegreeOfParallelismTests.cs @@ -40,7 +40,8 @@ public static IEnumerable NotLoadBalancedDegreeData(int[] counts, int[ [Theory] [MemberData(nameof(DegreeData), new[] { 1024 }, new[] { 1, 4, 512 })] - [OuterLoop] + [OuterLoop("Resource-intensive due to parallel processing", ~TestPlatforms.Browser)] + [SkipOnPlatform(TestPlatforms.Browser, "Not supported on browser")] public static void DegreeOfParallelism(Labeled> labeled, int count, int degree) { Assert.Equal(Functions.SumRange(0, count), labeled.Item.WithDegreeOfParallelism(degree).Sum()); @@ -93,7 +94,8 @@ public static void DegreeOfParallelism_Throttled_Pipelining(Labeled> labeled, int count, int degree) { ParallelQuery query = labeled.Item; @@ -111,7 +113,8 @@ public static void DegreeOfParallelism_Aggregate_Accumulator(Labeled> labeled, int count, int degree) { ParallelQuery query = labeled.Item; diff --git a/src/libraries/System.Linq.Parallel/tests/QueryOperators/ZipTests.cs b/src/libraries/System.Linq.Parallel/tests/QueryOperators/ZipTests.cs index c952169b8c37f..6531bdaffbedc 100644 --- a/src/libraries/System.Linq.Parallel/tests/QueryOperators/ZipTests.cs +++ b/src/libraries/System.Linq.Parallel/tests/QueryOperators/ZipTests.cs @@ -179,7 +179,8 @@ public static void Zip_NotPipelined_Longrunning(Labeled> left // Zip with ordering on showed issues, but it was due to the ordering component. // This is included as a regression test for that particular repro. [Theory] - [OuterLoop] + [OuterLoop("Resource-intensive due to parallel processing", ~TestPlatforms.Browser)] + [SkipOnPlatform(TestPlatforms.Browser, "Not supported on browser")] [MemberData(nameof(ZipThreadedData), new[] { 1, 2, 16, 128, 1024 }, new[] { 1, 2, 4, 7, 8, 31, 32 })] public static void Zip_AsOrdered_ThreadedDeadlock(Labeled> left, int leftCount, Labeled> right, int rightCount, int degree) { diff --git a/src/libraries/System.Net.WebSockets/tests/WebSocketCreateTest.cs b/src/libraries/System.Net.WebSockets/tests/WebSocketCreateTest.cs index 988f8e4eaaa92..e13d46fc708db 100644 --- a/src/libraries/System.Net.WebSockets/tests/WebSocketCreateTest.cs +++ b/src/libraries/System.Net.WebSockets/tests/WebSocketCreateTest.cs @@ -37,7 +37,7 @@ public void CreateFromStream_ValidBufferSizes_CreatesWebSocket() Assert.NotNull(CreateFromStream(new MemoryStream(), true, null, Timeout.InfiniteTimeSpan)); } - [OuterLoop("Uses external servers")] + [OuterLoop("Uses external servers", ~TestPlatforms.Browser)] [Theory] [MemberData(nameof(EchoServers))] [SkipOnPlatform(TestPlatforms.Browser, "System.Net.Sockets is not supported on this platform.")] @@ -230,7 +230,7 @@ public async Task ReceiveAsync_ServerSplitHeader_ValidDataReceived() } } - [OuterLoop("Uses external servers")] + [OuterLoop("Uses external servers", ~TestPlatforms.Browser)] [Theory] [MemberData(nameof(EchoServersAndBoolean))] [SkipOnPlatform(TestPlatforms.Browser, "System.Net.Sockets is not supported on this platform.")] @@ -272,7 +272,7 @@ public async Task WebSocketProtocol_CreateFromConnectedStream_CloseAsyncClosesSt } [ActiveIssue("https://github.com/dotnet/runtime/issues/28957")] - [OuterLoop("Uses external servers")] + [OuterLoop("Uses external servers", ~TestPlatforms.Browser)] [Theory] [MemberData(nameof(EchoServersAndBoolean))] [SkipOnPlatform(TestPlatforms.Browser, "System.Net.Sockets is not supported on this platform.")] diff --git a/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/Directory/Delete.cs b/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/Directory/Delete.cs index 5595984f7a1f7..afe8dc39fed3a 100644 --- a/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/Directory/Delete.cs +++ b/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/Directory/Delete.cs @@ -267,7 +267,7 @@ public void RecursiveDeleteWithTrailingSlash() [Fact] [PlatformSpecific(TestPlatforms.Windows)] - [OuterLoop("This test is very slow.")] + [OuterLoop("This test is very slow.", ~TestPlatforms.Browser)] public void RecursiveDelete_DeepNesting() { // Create a 2000 level deep directory and recursively delete from the root. diff --git a/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/File/EncryptDecrypt.cs b/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/File/EncryptDecrypt.cs index 23faf099319b6..a98234894890f 100644 --- a/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/File/EncryptDecrypt.cs +++ b/src/libraries/System.Runtime/tests/System.IO.FileSystem.Tests/File/EncryptDecrypt.cs @@ -29,7 +29,7 @@ public void NullArg_ThrowsException() // because EFS (Encrypted File System), its underlying technology, is not available on these operating systems. [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotWindowsNanoServer), nameof(PlatformDetection.IsNotWindowsHomeEdition))] [PlatformSpecific(TestPlatforms.Windows)] - [OuterLoop] // Occasional failures: https://github.com/dotnet/runtime/issues/12339 + [OuterLoop("Occasional failures", ~TestPlatforms.Browser)] // Occasional failures: https://github.com/dotnet/runtime/issues/12339 public void EncryptDecrypt_Read() { string tmpFileName = Path.GetTempFileName(); diff --git a/src/libraries/System.Security.Cryptography/tests/X509Certificates/CertTests.cs b/src/libraries/System.Security.Cryptography/tests/X509Certificates/CertTests.cs index a2479d92b7187..6f8a0b6c0bf87 100644 --- a/src/libraries/System.Security.Cryptography/tests/X509Certificates/CertTests.cs +++ b/src/libraries/System.Security.Cryptography/tests/X509Certificates/CertTests.cs @@ -425,7 +425,7 @@ public static void X509Cert2Test() [ActiveIssue("https://github.com/dotnet/runtime/issues/26213")] [ConditionalFact] - [OuterLoop("May require using the network, to download CRLs and intermediates")] + [OuterLoop("May require using the network, to download CRLs and intermediates", ~TestPlatforms.Browser)] public void TestVerify() { bool success; @@ -861,7 +861,7 @@ public static void CertificateSha3Signed() } [ConditionalFact(typeof(PlatformSupport), nameof(PlatformSupport.PlatformCryptoProviderFunctionalP256))] - [OuterLoop("Hardware backed key generation takes several seconds.")] + [OuterLoop("Hardware backed key generation takes several seconds.", ~TestPlatforms.Browser)] public static void CreateCertificate_MicrosoftPlatformCryptoProvider_EcdsaKey() { using (CngPlatformProviderKey platformKey = new CngPlatformProviderKey(CngAlgorithm.ECDsaP256)) @@ -882,7 +882,7 @@ public static void CreateCertificate_MicrosoftPlatformCryptoProvider_EcdsaKey() } [ConditionalFact(typeof(PlatformSupport), nameof(PlatformSupport.PlatformCryptoProviderFunctionalRsa))] - [OuterLoop("Hardware backed key generation takes several seconds.")] + [OuterLoop("Hardware backed key generation takes several seconds.", ~TestPlatforms.Browser)] public static void CreateCertificate_MicrosoftPlatformCryptoProvider_RsaKey() { using (CngPlatformProviderKey platformKey = new CngPlatformProviderKey(CngAlgorithm.Rsa)) diff --git a/src/libraries/System.Security.Cryptography/tests/X509Certificates/ChainTests.cs b/src/libraries/System.Security.Cryptography/tests/X509Certificates/ChainTests.cs index 210f36dcf6d57..c0e06c6a5a385 100644 --- a/src/libraries/System.Security.Cryptography/tests/X509Certificates/ChainTests.cs +++ b/src/libraries/System.Security.Cryptography/tests/X509Certificates/ChainTests.cs @@ -216,7 +216,7 @@ public static void TestResetMethod() /// and trusted root. It will fail to build any chain if those are not valid. /// [Fact] - [OuterLoop] + [OuterLoop("May take a long time on some platforms", ~TestPlatforms.Browser)] [SkipOnPlatform(TestPlatforms.Android, "Not supported on Android.")] public static void BuildChainExtraStoreUntrustedRoot() { @@ -656,7 +656,7 @@ public static void BuildChain_FailOnlyApplicationPolicy() } [ConditionalFact(nameof(TrustsMicrosoftDotComRoot))] - [OuterLoop(/* Modifies user certificate store */)] + [OuterLoop("Modifies user certificate store", ~TestPlatforms.Browser)] [SkipOnPlatform(PlatformSupport.MobileAppleCrypto, "Root certificate store is not accessible")] public static void BuildChain_MicrosoftDotCom_WithRootCertInUserAndSystemRootCertStores() { diff --git a/src/libraries/System.Security.Cryptography/tests/X509Certificates/ExportTests.cs b/src/libraries/System.Security.Cryptography/tests/X509Certificates/ExportTests.cs index 37526125041e9..1ddfb8418774b 100644 --- a/src/libraries/System.Security.Cryptography/tests/X509Certificates/ExportTests.cs +++ b/src/libraries/System.Security.Cryptography/tests/X509Certificates/ExportTests.cs @@ -173,7 +173,7 @@ public static void ExportAsPfxWithPrivateKey() [Fact] [PlatformSpecific(TestPlatforms.Windows)] - [OuterLoop("Modifies user-persisted state")] + [OuterLoop("Modifies user-persisted state", ~TestPlatforms.Browser)] public static void ExportDoesNotCorruptPrivateKeyMethods() { string keyName = $"clrtest.{Guid.NewGuid():D}"; diff --git a/src/libraries/System.Security.Cryptography/tests/X509Certificates/RevocationTests/DynamicRevocationTests.cs b/src/libraries/System.Security.Cryptography/tests/X509Certificates/RevocationTests/DynamicRevocationTests.cs index 56440ded4ed6c..015166f8f776c 100644 --- a/src/libraries/System.Security.Cryptography/tests/X509Certificates/RevocationTests/DynamicRevocationTests.cs +++ b/src/libraries/System.Security.Cryptography/tests/X509Certificates/RevocationTests/DynamicRevocationTests.cs @@ -10,7 +10,7 @@ namespace System.Security.Cryptography.X509Certificates.Tests.RevocationTests { - [OuterLoop("These tests run serially at about 1 second each, and the code shouldn't change that often.")] + [OuterLoop("These tests run serially at about 1 second each, and the code shouldn't change that often.", ~TestPlatforms.Browser)] [ConditionalClass(typeof(DynamicRevocationTests), nameof(SupportsDynamicRevocation))] [SkipOnPlatform(TestPlatforms.Browser, "Browser doesn't support X.509 certificates")] public static partial class DynamicRevocationTests diff --git a/src/libraries/System.Security.Cryptography/tests/X509Certificates/RevocationTests/TimeoutTests.cs b/src/libraries/System.Security.Cryptography/tests/X509Certificates/RevocationTests/TimeoutTests.cs index a0386f4e5c785..1e38859998d31 100644 --- a/src/libraries/System.Security.Cryptography/tests/X509Certificates/RevocationTests/TimeoutTests.cs +++ b/src/libraries/System.Security.Cryptography/tests/X509Certificates/RevocationTests/TimeoutTests.cs @@ -8,7 +8,7 @@ namespace System.Security.Cryptography.X509Certificates.Tests.RevocationTests { - [OuterLoop("These tests exercise timeout properties which take a lot of time.")] + [OuterLoop("These tests exercise timeout properties which take a lot of time.", ~TestPlatforms.Browser)] [SkipOnPlatform(TestPlatforms.Browser, "Browser doesn't support X.509 certificates")] public static class TimeoutTests { diff --git a/src/libraries/System.Text.RegularExpressions/tests/FunctionalTests/RegexIgnoreCaseTests.cs b/src/libraries/System.Text.RegularExpressions/tests/FunctionalTests/RegexIgnoreCaseTests.cs index 1d8ff187bb722..df515f5d66958 100644 --- a/src/libraries/System.Text.RegularExpressions/tests/FunctionalTests/RegexIgnoreCaseTests.cs +++ b/src/libraries/System.Text.RegularExpressions/tests/FunctionalTests/RegexIgnoreCaseTests.cs @@ -149,7 +149,7 @@ public async Task SourceGenerator_Supports_All_Cultures() // This test takes a long time to run since it needs to compute all possible lowercase mappings across // 3 different cultures and then creates Regex matches for all of our engines for each mapping. - [OuterLoop] + [OuterLoop("Takes long time to run", ~TestPlatforms.Browser)] [ActiveIssue("https://github.com/dotnet/runtime/issues/67793")] [Theory] [MemberData(nameof(Unicode_IgnoreCase_TestData))]