[tvOS] Skip symlink and named pipe tests that fail on iOS/tvOS#125503
Open
[tvOS] Skip symlink and named pipe tests that fail on iOS/tvOS#125503
Conversation
Contributor
|
Tagging subscribers to this area: @dotnet/area-system-io |
- GetFileType_SymbolicLink: replace [Fact] with [ConditionalFact(typeof(MountHelper), nameof(MountHelper.CanCreateSymbolicLinks))] to skip when symlinks cannot be created (e.g., tvOS) - GetFileType_NamedPipe: add [SkipOnPlatform(TestPlatforms.iOS | TestPlatforms.tvOS, ...)] since iOS/tvOS blocks binding to UNIX sockets Co-authored-by: adamsitnik <6011991+adamsitnik@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Fix UnauthorizedAccessException creating symlink on tvOS device
[tvOS] Skip symlink and named pipe tests that fail on iOS/tvOS
Mar 12, 2026
Member
|
/azp list |
This comment was marked as resolved.
This comment was marked as resolved.
Contributor
There was a problem hiding this comment.
Pull request overview
Adjusts Unix GetFileType tests to avoid consistent failures on iOS/tvOS where symlinks and FIFOs aren’t permitted/supported, reducing false CI failures on tvOS/arm64.
Changes:
- Skip
GetFileType_NamedPipeon iOS/tvOS. - Gate
GetFileType_SymbolicLinkbehindMountHelper.CanCreateSymbolicLinks.
You can also share your feedback on Copilot code review. Take the survey.
...libraries/System.Runtime/tests/System.IO.FileSystem.Tests/SafeFileHandle/GetFileType.Unix.cs
Outdated
Show resolved
Hide resolved
…SafeFileHandle/GetFileType.Unix.cs Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Member
|
For some reason all CI legs are cancelled, I am going to close and re-open the PR.. |
adamsitnik
approved these changes
Mar 12, 2026
Member
adamsitnik
left a comment
There was a problem hiding this comment.
LGTM assuming the tests are going to pass.
To other reviewers: I've checked how other symlink/mkfifo tests are annotated and just asked Copilot to apply these annotations for me.
This was referenced Mar 13, 2026
Open
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
tvOS (and iOS) raise
UnauthorizedAccessExceptionwhen creating symbolic links and return errors formkfifo, causingGetFileType_SymbolicLinkandGetFileType_NamedPipeto fail consistently on tvOS/arm64 CI legs.Changes
GetFileType_SymbolicLink: Replace[Fact]with[ConditionalFact(typeof(MountHelper), nameof(MountHelper.CanCreateSymbolicLinks))]— skips on any platform where symlink creation is not permitted (tvOS, unprivileged environments)GetFileType_NamedPipe: Add[SkipOnPlatform(TestPlatforms.iOS | TestPlatforms.tvOS, "iOS/tvOS blocks binding to UNIX sockets")]— consistent with the identical skip applied toNamedPipe_ReadWriteinDevicesPipesAndSockets.csDescription
SafeFileHandle_GetFileType_Unix.GetFileType_SymbolicLinkandGetFileType_NamedPipewere unconditionally running on all Unix platforms. tvOS prohibits symbolic link creation (EPERM) and does not supportmkfifo, causing both tests to fail on every tvOS CI run across both CoreCLR and Mono legs.Customer Impact
No customer impact; this is a test-only fix to stop recurring false CI failures on tvOS.
Regression
No — these tests never passed on tvOS. The failures surfaced as the tvOS leg became more active in CI.
Testing
The fixes mirror already-established skip patterns for the same platforms elsewhere in the same test assembly. No new logic is introduced in product code.
Risk
Minimal. Test-only change, no product code modified. The
MountHelper.CanCreateSymbolicLinksguard is already widely used across the symbolic link test suite;SkipOnPlatformfor iOS/tvOS is an established pattern in the same file's sibling tests.Package authoring no longer needed in .NET 9
IMPORTANT: Starting with .NET 9, you no longer need to edit a NuGet package's csproj to enable building and bump the version.
Keep in mind that we still need package authoring in .NET 8 and older versions.
Original prompt
This section details on the original issue you should resolve
<issue_title>UnauthorizedAccessException creating symlink on tvOS device (Operation not permitted)</issue_title>
<issue_description>Suggested labels:
Known Build Error,test-failure,os-tvos,arch-arm64,untriagedBuild Information
Build: 20260309.1, 20260310.2
Build error leg or test failing: System.IO.Tests.SafeFileHandle_GetFileType_Unix.GetFileType_SymbolicLink, System.IO.Tests.SafeFileHandle_GetFileType_Unix.GetFileType_NamedPipe, System.IO.FileSystem.Tests.WorkItemExecution
Affected CI jobs: build_tvos_arm64_Release_AllSubsets_CoreCLR, build_tvOS_arm64_Release_AllSubsets_Mono
Causing Commit Range Information
Commit range: {TODO: Insert commit range or link to changes}
Summary
Failure Statistics
Work Items
Showing 10 most recent of 12 occurrences
View Extract
View Extract
✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.