Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Re-enable System.IO.Pipes.Tests on iOS-based platforms #73258

Closed
wants to merge 4 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public abstract partial class PipeStream : Stream
private static readonly char[] s_invalidPathNameChars = Path.GetInvalidPathChars();

/// <summary>Prefix to prepend to all pipe names.</summary>
private static readonly string s_pipePrefix = Path.Combine(Path.GetTempPath(), "CoreFxPipe_");
private static readonly string s_pipePrefix = Path.Combine(Path.GetTempPath(), (RuntimeInformation.IsOSPlatform(OSPlatform.Create("TVOS"))) ? "x" : "CoreFxPipe_");

public override int Read(byte[] buffer, int offset, int count)
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -556,7 +556,6 @@ public async Task ReadBlockAsync_RepeatsReadsUntilReadDesiredAmount()
[InlineData(1, true)]
[SkipOnPlatform(TestPlatforms.Browser, "Not supported on Browser.")]
[SkipOnPlatform(TestPlatforms.LinuxBionic, "SElinux blocks UNIX sockets")]
[ActiveIssue("https://github.com/dotnet/runtime/issues/51390", TestPlatforms.iOS | TestPlatforms.tvOS | TestPlatforms.MacCatalyst)]
public async Task ReadAsync_Canceled_ThrowsException(int method, bool precanceled)
{
Func<StreamReader, CancellationToken, Task<int>> func = method switch
Expand All @@ -566,7 +565,7 @@ public async Task ReadAsync_Canceled_ThrowsException(int method, bool precancele
_ => throw new Exception("unknown mode")
};

string pipeName = Guid.NewGuid().ToString("N");
string pipeName = "x";
using (var serverStream = new NamedPipeServerStream(pipeName, PipeDirection.Out, 1, PipeTransmissionMode.Byte, PipeOptions.Asynchronous))
using (var clientStream = new NamedPipeClientStream(".", pipeName, PipeDirection.In, PipeOptions.Asynchronous))
{
Expand Down
5 changes: 0 additions & 5 deletions src/libraries/tests.proj
Original file line number Diff line number Diff line change
Expand Up @@ -329,11 +329,6 @@
<ProjectExclusions Include="$(MSBuildThisFileDirectory)System.Net.Security/tests/FunctionalTests/System.Net.Security.Tests.csproj" />
</ItemGroup>

<ItemGroup Condition="('$(TargetOS)' == 'iOS' or '$(TargetOS)' == 'iOSSimulator' or '$(TargetOS)' == 'tvOS' or '$(TargetOS)' == 'tvOSSimulator') and '$(RunDisablediOSTests)' != 'true'">
<!-- https://github.com/dotnet/runtime/issues/51335 -->
<ProjectExclusions Include="$(MSBuildThisFileDirectory)System.IO.Pipes/tests/System.IO.Pipes.Tests.csproj" />
</ItemGroup>

<ItemGroup Condition="'$(TargetOS)' == 'Browser' and '$(RunDisabledWasmTests)' != 'true' and '$(RunAOTCompilation)' != 'true'">
</ItemGroup>

Expand Down