From 0195ac371f384d3eb02642507a95b1e6b330541e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20K=C3=B6plinger?= Date: Fri, 10 Jul 2020 19:42:48 +0200 Subject: [PATCH 1/2] WASM: Add PlatformNotSupportedException for System.IO.Pipes The library isn't supported on WebAssembly. --- src/libraries/System.IO.Pipes/src/Resources/Strings.resx | 3 +++ src/libraries/System.IO.Pipes/src/System.IO.Pipes.csproj | 9 ++++++--- src/libraries/System.IO.Pipes/tests/AssemblyInfo.cs | 1 + .../System.IO.Pipes/tests/System.IO.Pipes.Tests.csproj | 1 + 4 files changed, 11 insertions(+), 3 deletions(-) diff --git a/src/libraries/System.IO.Pipes/src/Resources/Strings.resx b/src/libraries/System.IO.Pipes/src/Resources/Strings.resx index c8193e445cdbdd..e4777e219890c6 100644 --- a/src/libraries/System.IO.Pipes/src/Resources/Strings.resx +++ b/src/libraries/System.IO.Pipes/src/Resources/Strings.resx @@ -291,4 +291,7 @@ 'pipeSecurity' must be null when 'options' contains 'PipeOptions.CurrentUserOnly'. + + System.IO.Pipes is not supported on this platform + diff --git a/src/libraries/System.IO.Pipes/src/System.IO.Pipes.csproj b/src/libraries/System.IO.Pipes/src/System.IO.Pipes.csproj index b4411f32e4d75b..becae30a11a9db 100644 --- a/src/libraries/System.IO.Pipes/src/System.IO.Pipes.csproj +++ b/src/libraries/System.IO.Pipes/src/System.IO.Pipes.csproj @@ -3,11 +3,14 @@ System.IO.Pipes true true - $(NetCoreAppCurrent)-Windows_NT;$(NetCoreAppCurrent)-Unix;$(NetCoreAppCurrent)-Browser + $(NetCoreAppCurrent)-Windows_NT;$(NetCoreAppCurrent)-Unix;$(NetCoreAppCurrent) enable + + SR.Pipes_PlatformNotSupported + - + @@ -115,7 +118,7 @@ Link="Common\Interop\Windows\Interop.LoadLibraryEx_IntPtr.cs" /> - + diff --git a/src/libraries/System.IO.Pipes/tests/AssemblyInfo.cs b/src/libraries/System.IO.Pipes/tests/AssemblyInfo.cs index f9fdcb43917c49..394d602401c8c2 100644 --- a/src/libraries/System.IO.Pipes/tests/AssemblyInfo.cs +++ b/src/libraries/System.IO.Pipes/tests/AssemblyInfo.cs @@ -4,3 +4,4 @@ using Xunit; [assembly: ActiveIssue("https://github.com/dotnet/runtime/issues/34582", TestPlatforms.Windows, TargetFrameworkMonikers.Netcoreapp, TestRuntimes.Mono)] +[assembly: SkipOnMono("System.IO.Pipes is not supported on Browser", TestPlatforms.Browser)] diff --git a/src/libraries/System.IO.Pipes/tests/System.IO.Pipes.Tests.csproj b/src/libraries/System.IO.Pipes/tests/System.IO.Pipes.Tests.csproj index 4ae5348a1da4c9..5e032e88bd592e 100644 --- a/src/libraries/System.IO.Pipes/tests/System.IO.Pipes.Tests.csproj +++ b/src/libraries/System.IO.Pipes/tests/System.IO.Pipes.Tests.csproj @@ -3,6 +3,7 @@ true true $(NetCoreAppCurrent)-Windows_NT;$(NetCoreAppCurrent)-Unix;$(NetCoreAppCurrent)-Browser + true From 3956146fd42c08704db9e09a79bc78ba6ab771fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20K=C3=B6plinger?= Date: Fri, 10 Jul 2020 20:14:13 +0200 Subject: [PATCH 2/2] Make test TFMs match src TFMs --- .../System.IO.Pipes/tests/System.IO.Pipes.Tests.csproj | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libraries/System.IO.Pipes/tests/System.IO.Pipes.Tests.csproj b/src/libraries/System.IO.Pipes/tests/System.IO.Pipes.Tests.csproj index 5e032e88bd592e..bd2aabe486355f 100644 --- a/src/libraries/System.IO.Pipes/tests/System.IO.Pipes.Tests.csproj +++ b/src/libraries/System.IO.Pipes/tests/System.IO.Pipes.Tests.csproj @@ -2,7 +2,7 @@ true true - $(NetCoreAppCurrent)-Windows_NT;$(NetCoreAppCurrent)-Unix;$(NetCoreAppCurrent)-Browser + $(NetCoreAppCurrent)-Windows_NT;$(NetCoreAppCurrent)-Unix;$(NetCoreAppCurrent) true