Skip to content

[clr-ios] Preserve inherited MemberData statics on maccatalyst CoreCLR#128409

Open
kotlarmilos wants to merge 5 commits into
dotnet:mainfrom
kotlarmilos:kotlarmilos/fix-mobile-clr-test-failures
Open

[clr-ios] Preserve inherited MemberData statics on maccatalyst CoreCLR#128409
kotlarmilos wants to merge 5 commits into
dotnet:mainfrom
kotlarmilos:kotlarmilos/fix-mobile-clr-test-failures

Conversation

@kotlarmilos
Copy link
Copy Markdown
Member

@kotlarmilos kotlarmilos commented May 20, 2026

Description

On maccatalyst-arm64 AllSubsets_CoreCLR, ILLink strips the inherited ReadWrite_Success_MemberData and CopyToAsync_AllDataCopied_MemberData statics on ConnectedStreamConformanceTests, so xUnit's [MemberData] lookup fails for CryptoStreamTests.ReadWrite_Success and NetworkStreamTest.CopyToAsync_AllDataCopied. Adds a [DynamicDependency] on each derived override to root the base statics, and restores the IsMultithreadingSupported guard on CopyToAsync_AllDataCopied.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings May 20, 2026 15:33
@kotlarmilos kotlarmilos marked this pull request as draft May 20, 2026 15:33
@kotlarmilos
Copy link
Copy Markdown
Member Author

/azp run runtime-extra-platforms

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR adjusts a handful of library test cases to run (or skip) correctly on newly-enabled CoreCLR Apple mobile test legs by updating xUnit data discovery patterns and adding platform/trimming-related guards.

Changes:

  • Add/adjust theory data sourcing to avoid xUnit MemberData resolution problems in derived/overridden conformance tests.
  • Skip or expand existing platform exclusions for tests that rely on desktop-only behaviors (e.g., TPA/fusion log details, reflection emit under aggressive trimming).
  • Expand an existing ActiveIssue to include MacCatalyst and gate a debugger-proxy test away from NativeAOT.
Show a summary per file
File Description
src/libraries/System.Security.Cryptography/tests/CryptoStream.cs Adds an override using explicit MemberType for MemberData to stabilize conformance theory data discovery.
src/libraries/System.Runtime.Loader/tests/TpaLoadFailureTest.cs Skips path/fusion-log validation tests on Apple mobile where the assumptions don’t hold.
src/libraries/System.Reflection.Metadata/tests/Metadata/Decoding/CustomAttributeDecoderTests.cs Expands an ActiveIssue platform mask to include MacCatalyst.
src/libraries/System.Net.Sockets/tests/FunctionalTests/NetworkStreamTest.cs Adds an override to supply MemberType for MemberData on a conformance theory.
src/libraries/System.Linq.Expressions/tests/DebuggerTypeProxy/ExpressionDebuggerTypeProxyTests.cs Gates a reflection-heavy theory away from NativeAOT via ConditionalTheory.
src/libraries/Microsoft.Extensions.Hosting/tests/UnitTests/Internal/HostTests.cs Further gates Moq/RefEmit-based tests away from aggressively-trimmed/AOT-like environments.

Copilot's findings

  • Files reviewed: 6/6 changed files
  • Comments generated: 1

This was referenced May 21, 2026
@kotlarmilos
Copy link
Copy Markdown
Member Author

/azp run runtime-extra-platforms

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

@kotlarmilos kotlarmilos added the os-ios Apple iOS label May 22, 2026
@kotlarmilos kotlarmilos added this to the 11.0.0 milestone May 22, 2026
@dotnet-policy-service
Copy link
Copy Markdown
Contributor

Tagging subscribers to 'os-ios': @vitek-karas, @kotlarmilos, @steveisok, @akoeplinger
See info in area-owners.md if you want to be subscribed.

@kotlarmilos
Copy link
Copy Markdown
Member Author

/azp run runtime-extra-platforms

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot's findings

  • Files reviewed: 2/2 changed files
  • Comments generated: 2

Comment thread src/libraries/System.Security.Cryptography/tests/CryptoStream.cs Outdated
Comment thread src/libraries/System.Net.Sockets/tests/FunctionalTests/NetworkStreamTest.cs Outdated
@kotlarmilos
Copy link
Copy Markdown
Member Author

/azp run runtime, runtime-extra-platforms

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 2 pipeline(s).

kotlarmilos and others added 2 commits May 29, 2026 17:01
Per review suggestion: keep the MemberData and DynamicDependency
arguments in sync by using nameof(ConnectedStreamConformanceTests.X)
on both attributes, so they stay aligned if a same-named member is
later introduced on the derived class.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Combines the LinuxBionic and iOS|tvOS skips on the overrides into a
single SkipOnPlatform covering the mobile platforms that block AF_UNIX
binding. Drops the Wasi ActiveIssue and the IsMultithreadingSupported
ConditionalTheory since the System.Net.Sockets and CryptoStream tests
are not exercised on browser/wasi.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot's findings

  • Files reviewed: 2/2 changed files
  • Comments generated: 2

Comment thread src/libraries/System.Security.Cryptography/tests/CryptoStream.cs
@kotlarmilos
Copy link
Copy Markdown
Member Author

/azp run runtime-extra-platforms

@azure-pipelines
Copy link
Copy Markdown

Azure Pipelines successfully started running 1 pipeline(s).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area-Infrastructure-coreclr Only use for closed issues os-ios Apple iOS

Projects

Status: No status

Development

Successfully merging this pull request may close these issues.

2 participants