From e569b847a0e5fbcf847b29de234b2631cda204ff Mon Sep 17 00:00:00 2001 From: Milos Kotlar Date: Thu, 11 Jun 2026 10:23:27 +0200 Subject: [PATCH 1/4] Update SDK workload pipeline configuration Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- builds/Makefile | 1 - builds/package-download/download-packages.csproj | 2 -- tests/xharness/Jenkins/TestVariationsFactory.cs | 13 +++++++------ 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/builds/Makefile b/builds/Makefile index 38719d5b472e..42348b58ae87 100644 --- a/builds/Makefile +++ b/builds/Makefile @@ -105,7 +105,6 @@ package-download/all-package-references.csproj: $(GIT_DIRECTORY)/HEAD $(GIT_DIRE download-packages.csproj \ /t:WriteBundledNETCorePlatformsPackageVersion \ /p:WriteFilePath=$(CURDIR)/BundledNETCorePlatformsPackageVersion.txt \ - /p:PackageRuntimeIdentifiersMonoVM="$(DOTNET_MONOVM_RUNTIME_IDENTIFIERS)" \ /p:PackageRuntimeIdentifiersCoreCLR="$(DOTNET_CORECLR_RUNTIME_IDENTIFIERS)" \ /p:CustomDotNetVersion="$(DOWNLOAD_DOTNET_VERSION)" \ /p:TrackingDotNetRuntimeSeparately="$(TRACKING_DOTNET_RUNTIME_SEPARATELY)" \ diff --git a/builds/package-download/download-packages.csproj b/builds/package-download/download-packages.csproj index 09d492f4dad5..0c3c9378ff75 100644 --- a/builds/package-download/download-packages.csproj +++ b/builds/package-download/download-packages.csproj @@ -11,11 +11,9 @@ - - diff --git a/tests/xharness/Jenkins/TestVariationsFactory.cs b/tests/xharness/Jenkins/TestVariationsFactory.cs index 018b94238bda..010a0eda3e18 100644 --- a/tests/xharness/Jenkins/TestVariationsFactory.cs +++ b/tests/xharness/Jenkins/TestVariationsFactory.cs @@ -32,7 +32,7 @@ IEnumerable GetTestData (RunTestTask test) var x64_runtime_identifier = string.Empty; var arm64_sim_runtime_identifier = string.Empty; var x64_sim_runtime_identifier = string.Empty; - var supports_mono = test.Platform != TestPlatform.Mac; + var supports_mono = false; var supports_coreclr = true; var ignore_coreclr = ignore; @@ -90,10 +90,11 @@ IEnumerable GetTestData (RunTestTask test) yield return new TestData { Variation = "Debug (dynamic registrar)", TestVariation = "dynamic-registrar", Ignored = ignore }; yield return new TestData { Variation = "Release (all optimizations)", TestVariation = "release|static-registrar-all-optimizations", Ignored = ignore }; yield return new TestData { Variation = "Debug (all optimizations)", TestVariation = "static-registrar-all-optimizations", Ignored = ignore }; - if (supports_interpreter) { + if (supports_mono && supports_interpreter) { yield return new TestData { Variation = "Debug (interpreter)", TestVariation = "interpreter", Ignored = ignore }; } - yield return new TestData { Variation = "Release (LLVM)", TestVariation = "release|llvm", Ignored = ignore }; + if (supports_mono) + yield return new TestData { Variation = "Release (LLVM)", TestVariation = "release|llvm", Ignored = ignore }; yield return new TestData { Variation = "Debug (managed static registrar)", TestVariation = "managed-static-registrar", Ignored = ignore }; if (supports_coreclr) yield return new TestData { Variation = "Debug (trimmable static registrar)", TestVariation = "trimmable-static-registrar", Ignored = ignore }; @@ -127,7 +128,7 @@ IEnumerable GetTestData (RunTestTask test) yield return new TestData { Variation = "Release (trimmable static registrar, all optimizations)", TestVariation = "trimmable-static-registrar-all-optimizations-linkall", Ignored = ignore }; yield return new TestData { Variation = "Release (NativeAOT, x64)", TestVariation = "release|nativeaot", Ignored = ignore, RuntimeIdentifier = x64_sim_runtime_identifier }; yield return new TestData { Variation = "Release (trimmable static registrar, NativeAOT, x64)", TestVariation = "trimmable-static-registrar|release|nativeaot", Ignored = ignore, RuntimeIdentifier = x64_sim_runtime_identifier }; - if (supports_interpreter) { + if (supports_mono && supports_interpreter) { yield return new TestData { Variation = "Debug (interpreter)", TestVariation = "interpreter", Ignored = ignore }; yield return new TestData { Variation = "Release (interpreter)", TestVariation = "release|interpreter", Ignored = ignore }; } @@ -175,10 +176,10 @@ IEnumerable GetTestData (RunTestTask test) yield return new TestData { Variation = "Release (trimmable static registrar, NativeAOT, x64)", TestVariation = "trimmable-static-registrar|nativeaot|release", Ignored = ignore, RuntimeIdentifier = x64_runtime_identifier }; yield return new TestData { Variation = "Release (static registrar)", TestVariation = "release|static-registrar", Ignored = ignore }; yield return new TestData { Variation = "Release (static registrar, all optimizations)", TestVariation = "release|static-registrar-all-optimizations-linkall", Ignored = ignore }; - if (test.Platform == TestPlatform.MacCatalyst) { + if (supports_mono && test.Platform == TestPlatform.MacCatalyst) { yield return new TestData { Variation = "Release (ARM64, LLVM)", TestVariation = "release|llvm", Ignored = !mac_supports_arm64 ? true : ignore, RuntimeIdentifier = arm64_runtime_identifier }; } - if (supports_interpreter) { + if (supports_mono && supports_interpreter) { yield return new TestData { Variation = "Debug (interpreter)", TestVariation = "interpreter", Ignored = ignore }; yield return new TestData { Variation = "Release (interpreter)", TestVariation = "release|interpreter", Ignored = ignore }; } From b533d15db31c219fd7baa4a6485a0622329f097a Mon Sep 17 00:00:00 2001 From: Milos Kotlar Date: Wed, 10 Jun 2026 15:11:44 +0200 Subject: [PATCH 2/4] Update .NET 11 SDK to preview 6 (build 20260610.6) Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- eng/Version.Details.xml | 40 ++++++++++++++++++++-------------------- global.json | 6 +++--- 2 files changed, 23 insertions(+), 23 deletions(-) diff --git a/eng/Version.Details.xml b/eng/Version.Details.xml index 92ff89e19131..d1274a165907 100644 --- a/eng/Version.Details.xml +++ b/eng/Version.Details.xml @@ -1,29 +1,29 @@ - + https://github.com/dotnet/dotnet - d64191f29ec9042e2696d8b7d8326c4bd10ba268 + 8d5d82abe13ac88cf5b2343e77460243b5272a6b - + https://github.com/dotnet/dotnet - d64191f29ec9042e2696d8b7d8326c4bd10ba268 + 8d5d82abe13ac88cf5b2343e77460243b5272a6b - + https://github.com/dotnet/dotnet - d64191f29ec9042e2696d8b7d8326c4bd10ba268 + 8d5d82abe13ac88cf5b2343e77460243b5272a6b - + https://github.com/dotnet/dotnet - d64191f29ec9042e2696d8b7d8326c4bd10ba268 + 8d5d82abe13ac88cf5b2343e77460243b5272a6b - + https://github.com/dotnet/dotnet - d64191f29ec9042e2696d8b7d8326c4bd10ba268 + 8d5d82abe13ac88cf5b2343e77460243b5272a6b - + https://github.com/dotnet/dotnet - d64191f29ec9042e2696d8b7d8326c4bd10ba268 + 8d5d82abe13ac88cf5b2343e77460243b5272a6b @@ -61,25 +61,25 @@ - + https://github.com/dotnet/dotnet - d64191f29ec9042e2696d8b7d8326c4bd10ba268 + 8d5d82abe13ac88cf5b2343e77460243b5272a6b - + https://github.com/dotnet/dotnet - d64191f29ec9042e2696d8b7d8326c4bd10ba268 + 8d5d82abe13ac88cf5b2343e77460243b5272a6b - + https://github.com/dotnet/dotnet - d64191f29ec9042e2696d8b7d8326c4bd10ba268 + 8d5d82abe13ac88cf5b2343e77460243b5272a6b https://github.com/dotnet/xharness 866707736d49c2323628744716cda2475b3af9ee - + https://github.com/dotnet/dotnet - d64191f29ec9042e2696d8b7d8326c4bd10ba268 + 8d5d82abe13ac88cf5b2343e77460243b5272a6b diff --git a/global.json b/global.json index a67673b18507..944b0d6046a9 100644 --- a/global.json +++ b/global.json @@ -1,6 +1,6 @@ { "sdk": { - "version": "11.0.100-preview.5.26256.105", + "version": "11.0.100-preview.6.26310.106", "paths": [ "builds/downloads/dotnet", "$host$" @@ -8,9 +8,9 @@ "errorMessage": "The .NET SDK could not be found, please run 'make dotnet -C builds'." }, "tools": { - "dotnet": "11.0.100-preview.5.26256.105" + "dotnet": "11.0.100-preview.6.26310.106" }, "msbuild-sdks": { - "Microsoft.DotNet.Arcade.Sdk": "11.0.0-beta.26256.105" + "Microsoft.DotNet.Arcade.Sdk": "11.0.0-beta.26310.106" } } From 8d74b0f4c5ccae48117a6f986d30a9ae080de228 Mon Sep 17 00:00:00 2001 From: Milos Kotlar Date: Wed, 10 Jun 2026 16:47:21 +0200 Subject: [PATCH 3/4] Use validation package feed for SDK packages Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- NuGet.config | 1 + 1 file changed, 1 insertion(+) diff --git a/NuGet.config b/NuGet.config index de071dd918b2..47020d9d188d 100644 --- a/NuGet.config +++ b/NuGet.config @@ -8,6 +8,7 @@ + From b0e9a9cc8b459ca30a6d9a90b782a6fe80160c13 Mon Sep 17 00:00:00 2001 From: Milos Kotlar Date: Fri, 12 Jun 2026 11:40:44 +0200 Subject: [PATCH 4/4] [mobile] Remove Mono mobile dotnet build tests Remove the .NET unit tests that build iOS, tvOS and MacCatalyst apps with UseMonoRuntime=true. These resolve the Mono mobile runtime packs, which are no longer produced. macOS Mono cases are kept. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- tests/dotnet/UnitTests/BundleStructureTest.cs | 16 -- .../dotnet/UnitTests/IncrementalBuildTest.cs | 125 -------------- tests/dotnet/UnitTests/PostBuildTest.cs | 17 -- tests/dotnet/UnitTests/ProjectTest.cs | 158 ------------------ tests/dotnet/UnitTests/WindowsTest.cs | 18 -- 5 files changed, 334 deletions(-) diff --git a/tests/dotnet/UnitTests/BundleStructureTest.cs b/tests/dotnet/UnitTests/BundleStructureTest.cs index cd34d23c2cc6..ee2f112b9dee 100644 --- a/tests/dotnet/UnitTests/BundleStructureTest.cs +++ b/tests/dotnet/UnitTests/BundleStructureTest.cs @@ -634,22 +634,6 @@ public enum CodeSignature { All, } - [Test] - // Debug - [TestCase (ApplePlatform.iOS, "ios-arm64", CodeSignature.All, "Debug")] - [TestCase (ApplePlatform.iOS, "iossimulator-x64", CodeSignature.All, "Debug")] - [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-x64", CodeSignature.All, "Debug")] - [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-x64;maccatalyst-arm64", CodeSignature.All, "Debug")] - [TestCase (ApplePlatform.TVOS, "tvos-arm64", CodeSignature.All, "Debug")] - // Release - [TestCase (ApplePlatform.iOS, "ios-arm64", CodeSignature.All, "Release")] - [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-x64;maccatalyst-arm64", CodeSignature.All, "Release")] - [TestCase (ApplePlatform.TVOS, "tvos-arm64", CodeSignature.All, "Release")] - public void Build_Mono (ApplePlatform platform, string runtimeIdentifiers, CodeSignature signature, string configuration) - { - Build (platform, runtimeIdentifiers, signature, configuration, true); - } - [Test] // Debug [TestCase (ApplePlatform.iOS, "ios-arm64", CodeSignature.All, "Debug")] diff --git a/tests/dotnet/UnitTests/IncrementalBuildTest.cs b/tests/dotnet/UnitTests/IncrementalBuildTest.cs index 3adb664b3c4f..83c315733bc4 100644 --- a/tests/dotnet/UnitTests/IncrementalBuildTest.cs +++ b/tests/dotnet/UnitTests/IncrementalBuildTest.cs @@ -4,14 +4,6 @@ namespace Xamarin.Tests { public class IncrementalBuildTest : TestBaseClass { - [Test] - // this test is fairly slow, so execute on one arch only - [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64")] - public void Link_Mono (ApplePlatform platform, string runtimeIdentifiers) - { - LinkImpl (platform, runtimeIdentifiers, useMonoRuntime: true); - } - [Test] // this test is fairly slow, so execute on one arch only [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64")] @@ -123,113 +115,6 @@ static IEnumerable GetLoadCommands (string dylib) } } - [Test] - [TestCase (ApplePlatform.iOS, "ios-arm64")] - public void NativeLink (ApplePlatform platform, string runtimeIdentifiers) - { - Configuration.IgnoreIfIgnoredPlatform (platform); - Configuration.AssertRuntimeIdentifiersAvailable (platform, runtimeIdentifiers); - - var project_path = GenerateProject (platform, name: nameof (NativeLink), runtimeIdentifiers: runtimeIdentifiers, out var appPath); - var properties = new Dictionary (verbosity); - properties ["UseMonoRuntime"] = "true"; // this test is only applicable to Mono. - SetRuntimeIdentifiers (properties, runtimeIdentifiers); - - var mainContents = @" -class MainClass { - static int Main () - { - return 123; - } -} -"; - var mainFile = Path.Combine (Path.GetDirectoryName (project_path)!, "Main.cs"); - - File.WriteAllText (mainFile, mainContents); - - // Build the first time - var rv = DotNet.AssertBuild (project_path, properties); - var allTargets = BinLog.GetAllTargets (rv.BinLogPath); - AssertTargetExecuted (allTargets, "_AOTCompile", "A"); - AssertTargetExecuted (allTargets, "_CompileNativeExecutable", "A"); - AssertTargetExecuted (allTargets, "_LinkNativeExecutable", "A"); - - // Capture the current time - var timestamp = DateTime.UtcNow; - File.WriteAllText (mainFile, mainContents); - - // Build again - rv = DotNet.AssertBuild (project_path, properties); - - // Check that some targets executed - allTargets = BinLog.GetAllTargets (rv.BinLogPath); - AssertTargetExecuted (allTargets, "_AOTCompile", "B"); - AssertTargetNotExecuted (allTargets, "_CompileNativeExecutable", "B"); - AssertTargetExecuted (allTargets, "_LinkNativeExecutable", "B"); - - // Verify that the timestamp of the executable has been updated - var executable = GetNativeExecutable (platform, appPath!); - Assert.That (File.GetLastWriteTimeUtc (executable), Is.GreaterThan (timestamp), "B: Executable modified"); - } - - [Test] - // this test is fairly slow, so execute on one arch only - [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64")] - public void Interpreter (ApplePlatform platform, string runtimeIdentifiers) - { - var project = "MySimpleApp"; - Configuration.IgnoreIfIgnoredPlatform (platform); - Configuration.AssertRuntimeIdentifiersAvailable (platform, runtimeIdentifiers); - - var project_path = GetProjectPath (project, runtimeIdentifiers: runtimeIdentifiers, platform: platform, out var appPath); - Clean (project_path); - var properties = GetDefaultProperties (runtimeIdentifiers); - - properties ["UseMonoRuntime"] = "true"; // only applicable when using MonoVM. - - // Build with the interpreter disabled - properties ["UseInterpreter"] = "false"; - DotNet.AssertBuild (project_path, properties); - - // Make sure it runs successfully (if on desktop) - var appExecutable = GetNativeExecutable (platform, appPath); - ExecuteWithMagicWordAndAssert (platform, runtimeIdentifiers, appExecutable); - - // Capture when executable was created - var appExecutableTimestamp = File.GetLastWriteTimeUtc (appExecutable); - - // Build again, now enabling the interpreter - Configuration.Touch (project_path); - properties ["UseInterpreter"] = "true"; - DotNet.AssertBuild (project_path, properties); - - // Executing should work just fine - ExecuteWithMagicWordAndAssert (platform, runtimeIdentifiers, appExecutable); - - // The main executable must be modified - Assert.That (File.GetLastWriteTimeUtc (appExecutable), Is.GreaterThan (appExecutableTimestamp), "Modified A"); - - // Capture when executable was rebuilt - appExecutableTimestamp = File.GetLastWriteTimeUtc (appExecutable); - - // Build again, not doing anything - DotNet.AssertBuild (project_path, properties); - - // Executing should work just fine - ExecuteWithMagicWordAndAssert (platform, runtimeIdentifiers, appExecutable); - - // The main executable must not be modified - Assert.That (File.GetLastWriteTimeUtc (appExecutable), Is.EqualTo (appExecutableTimestamp), "Modified B"); - } - - [Test] - [TestCase (ApplePlatform.iOS, "iossimulator-arm64", true)] - [TestCase (ApplePlatform.iOS, "iossimulator-arm64", false)] - public void CodeChangeSkipsTargets_Mono (ApplePlatform platform, string runtimeIdentifiers, bool interpreterEnabled) - { - CodeChangeSkipsTargetsImpl (platform, runtimeIdentifiers, useMonoRuntime: true, interpreterEnabled: interpreterEnabled); - } - [Test] [TestCase (ApplePlatform.iOS, "iossimulator-arm64")] public void CodeChangeSkipsTargets_CoreCLR (ApplePlatform platform, string runtimeIdentifiers) @@ -239,16 +124,6 @@ public void CodeChangeSkipsTargets_CoreCLR (ApplePlatform platform, string runti CodeChangeSkipsTargetsImpl (platform, runtimeIdentifiers, useMonoRuntime: false, interpreterEnabled: false); } - [Test] - [Category ("RemoteWindows")] - [TestCase (ApplePlatform.iOS, "iossimulator-arm64", true)] - [TestCase (ApplePlatform.iOS, "iossimulator-arm64", false)] - public void CodeChangeSkipsTargetsOnRemoteWindows_Mono (ApplePlatform platform, string runtimeIdentifiers, bool interpreterEnabled) - { - Configuration.IgnoreIfNotOnWindows (); - CodeChangeSkipsTargetsImpl (platform, runtimeIdentifiers, useMonoRuntime: true, interpreterEnabled: interpreterEnabled); - } - [Test] [Category ("RemoteWindows")] [TestCase (ApplePlatform.iOS, "iossimulator-arm64")] diff --git a/tests/dotnet/UnitTests/PostBuildTest.cs b/tests/dotnet/UnitTests/PostBuildTest.cs index a525a1881d42..59d0a7f2faf5 100644 --- a/tests/dotnet/UnitTests/PostBuildTest.cs +++ b/tests/dotnet/UnitTests/PostBuildTest.cs @@ -48,14 +48,6 @@ public void ArchiveTest (ApplePlatform platform, string runtimeIdentifiers) AssertDSymDirectory (appPath); } - [Test] - [TestCase (ApplePlatform.iOS, "ios-arm64")] - [TestCase (ApplePlatform.TVOS, "tvos-arm64")] - public void BuildIpaTest_Mono (ApplePlatform platform, string runtimeIdentifiers) - { - BuildIpaTestImpl (platform, runtimeIdentifiers, useMonoRuntime: true); - } - [Test] [TestCase (ApplePlatform.iOS, "ios-arm64")] [TestCase (ApplePlatform.TVOS, "tvos-arm64")] @@ -229,15 +221,6 @@ public void BuildPackageTest (string project, ApplePlatform platform, string run Assert.That (pkgPath, Does.Exist, "pkg creation"); } - [TestCase (ApplePlatform.iOS, "ios-arm64")] - [TestCase (ApplePlatform.TVOS, "tvos-arm64")] - [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64")] - [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64;maccatalyst-x64")] - public void PublishTest_Mono (ApplePlatform platform, string runtimeIdentifiers) - { - PublishTestImpl (platform, runtimeIdentifiers, useMonoRuntime: true); - } - [TestCase (ApplePlatform.iOS, "ios-arm64")] [TestCase (ApplePlatform.TVOS, "tvos-arm64")] [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64")] diff --git a/tests/dotnet/UnitTests/ProjectTest.cs b/tests/dotnet/UnitTests/ProjectTest.cs index f56013f3811d..9d02e9e686b5 100644 --- a/tests/dotnet/UnitTests/ProjectTest.cs +++ b/tests/dotnet/UnitTests/ProjectTest.cs @@ -453,18 +453,6 @@ public void InvalidRuntimeIdentifiers (ApplePlatform platform, string runtimeIde Assert.That (errors [0].Message, Is.EqualTo ($"Building for all the runtime identifiers '{runtimeIdentifiers}' at the same time isn't possible, because they represent different platform variations."), "Error message"); } - [Test] - [TestCase (ApplePlatform.iOS, "iossimulator-x64", false)] - [TestCase (ApplePlatform.iOS, "ios-arm64", true)] - [TestCase (ApplePlatform.iOS, "ios-arm64", true, null, "Release")] - [TestCase (ApplePlatform.iOS, "ios-arm64", true, "UseInterpreter=true")] - [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64;maccatalyst-x64", false)] - [Category ("WindowsInclusive")] - public void IsNotMacBuild_Mono (ApplePlatform platform, string runtimeIdentifiers, bool isDeviceBuild, string? extraProperties = null, string configuration = "Debug") - { - IsNotMacBuild (platform, runtimeIdentifiers, isDeviceBuild, extraProperties, configuration, useMonoRuntime: true); - } - [Test] [TestCase (ApplePlatform.iOS, "iossimulator-x64", false)] [TestCase (ApplePlatform.iOS, "ios-arm64", true)] @@ -2250,13 +2238,6 @@ public void CustomAppBundleDir (ApplePlatform platform, string runtimeIdentifier var result = DotNet.AssertBuild (project_path, properties); } - [TestCase (ApplePlatform.iOS, "ios-arm64")] - [TestCase (ApplePlatform.iOS, "iossimulator-x64;iossimulator-arm64")] - public void PluralRuntimeIdentifiers_Mono (ApplePlatform platform, string runtimeIdentifiers) - { - PluralRuntimeIdentifiersImpl (platform, runtimeIdentifiers, useMonoRuntime: true); - } - [TestCase (ApplePlatform.iOS, "ios-arm64")] [TestCase (ApplePlatform.iOS, "iossimulator-x64;iossimulator-arm64")] public void PluralRuntimeIdentifiers_CoreCLR (ApplePlatform platform, string runtimeIdentifiers) @@ -2953,99 +2934,6 @@ public void RaisesAppDomainUnhandledExceptionEvent (ApplePlatform platform) } } - bool FindAOTedAssemblyFile (string path, string dllName) - { - var aotedAssemblyFileName = $"{dllName}.o"; - foreach (string file in Directory.GetFiles (path, "*.o", SearchOption.AllDirectories)) { - if (Path.GetFileName (file).Equals (aotedAssemblyFileName, StringComparison.OrdinalIgnoreCase)) { - return true; - } - } - - return false; - } - - [Test] - [TestCase (ApplePlatform.iOS, "ios-arm64", "-all,System.Private.CoreLib")] - [TestCase (ApplePlatform.iOS, "ios-arm64", "all,-System.Private.CoreLib")] - [TestCase (ApplePlatform.iOS, "ios-arm64", "")] - [TestCase (ApplePlatform.TVOS, "tvos-arm64", "-all,System.Private.CoreLib")] - [TestCase (ApplePlatform.TVOS, "tvos-arm64", "all,-System.Private.CoreLib")] - [TestCase (ApplePlatform.TVOS, "tvos-arm64", "")] - public void DedupEnabledTest (ApplePlatform platform, string runtimeIdentifiers, string mtouchInterpreter) - { - var project = "MySimpleApp"; - Configuration.IgnoreIfIgnoredPlatform (platform); - Configuration.AssertRuntimeIdentifiersAvailable (platform, runtimeIdentifiers); - - var project_path = GetProjectPath (project, runtimeIdentifiers: runtimeIdentifiers, platform: platform, out var appPath); - Clean (project_path); - var properties = GetDefaultProperties (runtimeIdentifiers); - properties ["MtouchInterpreter"] = $"\"{mtouchInterpreter}\""; - properties ["UseMonoRuntime"] = "true"; // this test only apples when using Mono - DotNet.AssertBuild (project_path, properties); - - var objDir = GetObjDir (project_path, platform, runtimeIdentifiers); - Assert.That (FindAOTedAssemblyFile (objDir, "aot-instances.dll"), Is.True, $"Dedup optimization should be enabled for AOT compilation on: {platform} with RID: {runtimeIdentifiers}"); - } - - [Test] - [TestCase (ApplePlatform.iOS, "iossimulator-x64", "-all,System.Private.CoreLib")] - [TestCase (ApplePlatform.iOS, "iossimulator-x64", "all,-System.Private.CoreLib")] - [TestCase (ApplePlatform.iOS, "iossimulator-x64", "")] - [TestCase (ApplePlatform.TVOS, "tvossimulator-x64", "-all,System.Private.CoreLib")] - [TestCase (ApplePlatform.TVOS, "tvossimulator-x64", "all,-System.Private.CoreLib")] - [TestCase (ApplePlatform.TVOS, "tvossimulator-x64", "")] - public void DedupDisabledTest (ApplePlatform platform, string runtimeIdentifiers, string mtouchInterpreter) - { - var project = "MySimpleApp"; - Configuration.IgnoreIfIgnoredPlatform (platform); - Configuration.AssertRuntimeIdentifiersAvailable (platform, runtimeIdentifiers); - - var project_path = GetProjectPath (project, runtimeIdentifiers: runtimeIdentifiers, platform: platform, out var appPath); - Clean (project_path); - var properties = GetDefaultProperties (runtimeIdentifiers); - properties ["MtouchInterpreter"] = $"\"{mtouchInterpreter}\""; - properties ["UseMonoRuntime"] = "true"; // this test only apples when using Mono - - DotNet.AssertBuild (project_path, properties); - - var objDir = GetObjDir (project_path, platform, runtimeIdentifiers); - Assert.That (FindAOTedAssemblyFile (objDir, "aot-instances.dll"), Is.False, $"Dedup optimization should not be enabled for AOT compilation on: {platform} with RID: {runtimeIdentifiers}"); - } - - [Test] - [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64;maccatalyst-x64", "-all,System.Private.CoreLib")] - [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64;maccatalyst-x64", "all,-System.Private.CoreLib")] - [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64;maccatalyst-x64", "")] - public void DedupUniversalAppTest (ApplePlatform platform, string runtimeIdentifiers, string mtouchInterpreter) - { - var project = "MySimpleApp"; - Configuration.IgnoreIfIgnoredPlatform (platform); - Configuration.AssertRuntimeIdentifiersAvailable (platform, runtimeIdentifiers); - - var project_path = GetProjectPath (project, runtimeIdentifiers: runtimeIdentifiers, platform: platform, out var appPath); - Clean (project_path); - var properties = GetDefaultProperties (runtimeIdentifiers); - properties ["MtouchInterpreter"] = $"\"{mtouchInterpreter}\""; - properties ["UseMonoRuntime"] = "true"; // this test only apples when using Mono - - DotNet.AssertBuild (project_path, properties); - - var objDir = GetObjDir (project_path, platform, runtimeIdentifiers); - var objDirMacCatalystArm64 = Path.Combine (objDir, "maccatalyst-arm64"); - Assert.That (FindAOTedAssemblyFile (objDirMacCatalystArm64, "aot-instances.dll"), Is.True, $"Dedup optimization should be enabled for AOT compilation on: {platform} with RID: maccatalyst-arm64"); - - var objDirMacCatalystx64 = Path.Combine (objDir, "maccatalyst-x64"); - Assert.That (FindAOTedAssemblyFile (objDirMacCatalystx64, "aot-instances.dll"), Is.False, $"Dedup optimization should not be enabled for AOT compilation on: {platform} with RID: maccatalyst-x64"); - - var appExecutable = GetNativeExecutable (platform, appPath); - - if (CanExecute (platform, runtimeIdentifiers)) { - ExecuteWithMagicWordAndAssert (appExecutable); - } - } - [Test] [TestCase (ApplePlatform.MacOSX, "osx-arm64;osx-x64")] [TestCase (ApplePlatform.MacCatalyst, "maccatalyst-arm64;maccatalyst-x64")] @@ -3282,11 +3170,6 @@ public void AppendRuntimeIdentifierToOutputPath_DisableDirectoryBuildProps (Appl "/usr/lib/swift/libswiftXPC.dylib", ]; - static string [] expectedFrameworks_iOS_None_Mono = [ - .. expectedFrameworks_iOS_None, - "/System/Library/Frameworks/CryptoKit.framework/CryptoKit", - ]; - static string [] expectedFrameworks_iOS_Full = [ "/System/Library/Frameworks/CFNetwork.framework/CFNetwork", "/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation", @@ -3303,8 +3186,6 @@ public void AppendRuntimeIdentifierToOutputPath_DisableDirectoryBuildProps (Appl "/usr/lib/libz.1.dylib", ]; - static string [] expectedFrameworks_iOS_Full_Mono = expectedFrameworks_iOS_Full; - static string [] expectedFrameworks_tvOS_None = [ "/System/Library/Frameworks/Accelerate.framework/Accelerate", "/System/Library/Frameworks/Accessibility.framework/Accessibility", @@ -3417,11 +3298,6 @@ public void AppendRuntimeIdentifierToOutputPath_DisableDirectoryBuildProps (Appl "/usr/lib/swift/libswiftXPC.dylib", ]; - static string [] expectedFrameworks_tvOS_None_Mono = [ - .. expectedFrameworks_tvOS_None, - "/System/Library/Frameworks/CryptoKit.framework/CryptoKit", - ]; - static string [] expectedFrameworks_tvOS_Full = [ "/System/Library/Frameworks/CoreFoundation.framework/CoreFoundation", "/System/Library/Frameworks/Foundation.framework/Foundation", @@ -3436,8 +3312,6 @@ public void AppendRuntimeIdentifierToOutputPath_DisableDirectoryBuildProps (Appl "/usr/lib/libz.1.dylib", ]; - static string [] expectedFrameworks_tvOS_Full_Mono = expectedFrameworks_tvOS_Full; - static string [] expectedFrameworks_macOS_None = [ "@executable_path/../../Contents/MonoBundle/libclrgc.dylib", "@executable_path/../../Contents/MonoBundle/libclrgcexp.dylib", @@ -3801,11 +3675,6 @@ public void AppendRuntimeIdentifierToOutputPath_DisableDirectoryBuildProps (Appl "/usr/lib/swift/libswiftXPC.dylib", ]; - static string [] expectedFrameworks_MacCatalyst_None_Mono = [ - .. expectedFrameworks_MacCatalyst_None, - "/System/Library/Frameworks/CryptoKit.framework/Versions/A/CryptoKit", - ]; - static string [] expectedFrameworks_MacCatalyst_Full = [ "/System/iOSSupport/System/Library/Frameworks/UIKit.framework/Versions/A/UIKit", "/System/Library/Frameworks/AppKit.framework/Versions/C/AppKit", @@ -3826,8 +3695,6 @@ public void AppendRuntimeIdentifierToOutputPath_DisableDirectoryBuildProps (Appl "/usr/lib/libz.1.dylib", ]; - static string [] expectedFrameworks_MacCatalyst_Full_Mono = expectedFrameworks_MacCatalyst_Full; - static string [] expectedFrameworks_iOS_None_CoreCLR = [ .. coreclrFrameworks_iOS, .. expectedFrameworks_iOS_None, @@ -3853,25 +3720,6 @@ public void AppendRuntimeIdentifierToOutputPath_DisableDirectoryBuildProps (Appl .. expectedFrameworks_MacCatalyst_Full, ]; - static IEnumerable GetLinkedWithNativeLibrariesTestCases_Mono () - { - // Generally speaking, whenever we bind a new framework, we'll have to adjust the LinkMode="None" test cases, - // but we shouldn't have to adjust the LinkMode="Full" test cases (which would typically mean that we'll end - // up linking with said framework in every app - it's also an indication that we're not trimming away as much - // as we want, because just adding an (unused) framework shouldn't make it impossible to trim away all the - // code in that framework). - // - // However, new .NET versions often require updates to both the "None" and "Full lists of frameworks and libraries. - // - - yield return new TestCaseData (ApplePlatform.iOS, "ios-arm64", "None", expectedFrameworks_iOS_None_Mono); - yield return new TestCaseData (ApplePlatform.iOS, "ios-arm64", "Full", expectedFrameworks_iOS_Full_Mono); - yield return new TestCaseData (ApplePlatform.TVOS, "tvos-arm64", "None", expectedFrameworks_tvOS_None_Mono); - yield return new TestCaseData (ApplePlatform.TVOS, "tvos-arm64", "Full", expectedFrameworks_tvOS_Full_Mono); - yield return new TestCaseData (ApplePlatform.MacCatalyst, "maccatalyst-x64", "None", expectedFrameworks_MacCatalyst_None_Mono); - yield return new TestCaseData (ApplePlatform.MacCatalyst, "maccatalyst-x64", "Full", expectedFrameworks_MacCatalyst_Full_Mono); - } - static IEnumerable GetLinkedWithNativeLibrariesTestCases_CoreCLR () { // Generally speaking, whenever we bind a new framework, we'll have to adjust the LinkMode="None" test cases, @@ -3893,12 +3741,6 @@ static IEnumerable GetLinkedWithNativeLibrariesTestCases_CoreCLR ( yield return new TestCaseData (ApplePlatform.MacCatalyst, "maccatalyst-x64", "Full", expectedFrameworks_MacCatalyst_Full_CoreCLR); } - [TestCaseSource (nameof (GetLinkedWithNativeLibrariesTestCases_Mono))] - public void LinkedWithNativeLibraries_Mono (ApplePlatform platform, string runtimeIdentifiers, string linkMode, string [] expectedFrameworks) - { - LinkedWithNativeLibraries (platform, runtimeIdentifiers, linkMode, expectedFrameworks, useMonoRuntime: true); - } - [TestCaseSource (nameof (GetLinkedWithNativeLibrariesTestCases_CoreCLR))] public void LinkedWithNativeLibraries_CoreCLR (ApplePlatform platform, string runtimeIdentifiers, string linkMode, string [] expectedFrameworks) { diff --git a/tests/dotnet/UnitTests/WindowsTest.cs b/tests/dotnet/UnitTests/WindowsTest.cs index e9ac09f1b7a9..5342b88a980c 100644 --- a/tests/dotnet/UnitTests/WindowsTest.cs +++ b/tests/dotnet/UnitTests/WindowsTest.cs @@ -114,13 +114,6 @@ void AssertMaxFileLengthInBinAndObjDirectories (ApplePlatform platform, string p } } - [Category ("RemoteWindows")] - [TestCase (ApplePlatform.iOS, "ios-arm64", BundleStructureTest.CodeSignature.All, "Debug")] - public void BundleStructureWithRemoteMac_Mono (ApplePlatform platform, string runtimeIdentifiers, BundleStructureTest.CodeSignature signature, string configuration) - { - BundleStructureWithRemoteMac (platform, runtimeIdentifiers, signature, configuration, useMonoRuntime: true); - } - [Category ("RemoteWindows")] [TestCase (ApplePlatform.iOS, "ios-arm64", BundleStructureTest.CodeSignature.All, "Debug")] public void BundleStructureWithRemoteMac_CoreCLR (ApplePlatform platform, string runtimeIdentifiers, BundleStructureTest.CodeSignature signature, string configuration) @@ -276,16 +269,6 @@ void BundleStructureWithRemoteMac (ApplePlatform platform, string runtimeIdentif AssertMaxFileLengthInBinAndObjDirectories (platform, project_path, runtimeIdentifiers, configuration, maxLength: maxPathLength); } - [Category ("RemoteWindows")] - [TestCase (ApplePlatform.iOS, "ios-arm64")] - [TestCase (ApplePlatform.iOS, "iossimulator-arm64;iossimulator-x64")] - [Ignore ("https://github.com/dotnet/macios/issues/25438")] - public void PluralRuntimeIdentifiersWithRemoteMac_Mono (ApplePlatform platform, string runtimeIdentifiers) - { - var properties = AddRemoteProperties (); - DotNetProjectTest.PluralRuntimeIdentifiersImpl (platform, runtimeIdentifiers, useMonoRuntime: true, extraProperties: properties); - } - [Category ("RemoteWindows")] [TestCase (ApplePlatform.iOS, "ios-arm64")] [TestCase (ApplePlatform.iOS, "iossimulator-arm64;iossimulator-x64")] @@ -368,7 +351,6 @@ public void StripTest (ApplePlatform platform, string runtimeIdentifiers, string } [Category ("RemoteWindows")] - [TestCase (ApplePlatform.iOS, "ios-arm64", "Debug", true)] [TestCase (ApplePlatform.iOS, "ios-arm64", "Debug", false)] [TestCase (ApplePlatform.iOS, "ios-arm64", "Release", false)] public void RemoteTest (ApplePlatform platform, string runtimeIdentifiers, string configuration, bool useMonoRuntime)