diff --git a/tests/monotouch-test/UIKit/SearchDisplayControllerTest.cs b/tests/monotouch-test/UIKit/SearchDisplayControllerTest.cs
index 16ba5b1c38..7bd0209da5 100644
--- a/tests/monotouch-test/UIKit/SearchDisplayControllerTest.cs
+++ b/tests/monotouch-test/UIKit/SearchDisplayControllerTest.cs
@@ -7,7 +7,7 @@
// Copyright 2012 Xamarin Inc. All rights reserved.
//
-#if !XAMCORE_3_0 && !MONOMAC
+#if !XAMCORE_3_0 && !MONOMAC && !__MACCATALYST__
using System;
using System.Drawing;
diff --git a/tests/monotouch-test/dotnet/MacCatalyst/Info.plist b/tests/monotouch-test/dotnet/MacCatalyst/Info.plist
new file mode 100644
index 0000000000..40d38af7a0
--- /dev/null
+++ b/tests/monotouch-test/dotnet/MacCatalyst/Info.plist
@@ -0,0 +1,66 @@
+
+
+
+
+ CFBundleDisplayName
+ MonoTouchTest
+ CFBundleIdentifier
+ com.xamarin.monotouch-test
+ CFBundleName
+ MonoTouchTest
+ LSMinimumSystemVersion
+ 10.15
+ NSAppTransportSecurity
+
+ NSAllowsArbitraryLoads
+
+
+ NSAppleMusicUsageDescription
+ Testing tastes
+ NSCameraUsageDescription
+ Smile!
+ NSContactsUsageDescription
+ Testing friends
+ NSHomeKitUsageDescription
+ Testing roofs
+ NSMicrophoneUsageDescription
+ Testing mike
+ NSPhotoLibraryUsageDescription
+ Testing lens
+ NSBluetoothAlwaysUsageDescription
+ Testing world domination through blue teeth coloring
+ UIDeviceFamily
+
+ 1
+ 2
+
+ UILaunchStoryboardName
+ LaunchScreen
+ UIRequiresFullScreen
+
+ UISupportedInterfaceOrientations
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ UISupportedInterfaceOrientations~ipad
+
+ UIInterfaceOrientationPortrait
+ UIInterfaceOrientationPortraitUpsideDown
+ UIInterfaceOrientationLandscapeLeft
+ UIInterfaceOrientationLandscapeRight
+
+ XSAppIconAssets
+ Assets.xcassets/AppIcons.appiconset
+ BGTaskSchedulerPermittedIdentifiers
+
+ com.xamarin.monotouch-test.TesgBackgroundTask
+
+ UIBackgroundModes
+
+ processing
+
+
+
diff --git a/tests/monotouch-test/dotnet/MacCatalyst/monotouch-test.csproj b/tests/monotouch-test/dotnet/MacCatalyst/monotouch-test.csproj
new file mode 100644
index 0000000000..9f1ff34a42
--- /dev/null
+++ b/tests/monotouch-test/dotnet/MacCatalyst/monotouch-test.csproj
@@ -0,0 +1,193 @@
+
+
+
+ net6.0-maccatalyst
+ maccatalyst-x64
+ Exe
+ NET
+ latest
+ monotouchtest
+ monotouchtest
+ True
+ ..\..\..\..\product.snk
+ True
+ ..\..\Entitlements.plist
+ xamarinios10;$(AssetTargetFallback)
+ $(DefineConstants);DYNAMIC_REGISTRAR
+ $(DefineConstants);DEVICE
+ ..\..\..
+ None
+ -xml=${ProjectDir}/../extra-linker-defs.xml
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ %(RecursiveDir)%(Filename).cs
+
+
+
+
+ shared\ObjCRuntime\RegistrarTest.cs
+
+
+ CoreFoundation\CFNotificationCenterTest.cs
+
+
+ TestRuntime.cs
+
+
+ ConditionalCompilation.cs
+
+
+ Extensions.cs
+
+
+
+
+
+ AudioToolbox\1.caf
+
+
+ Tamarin.pdf
+
+
+ basn3p08.png
+
+
+ BoardingPass.pkpass
+
+
+ Hand.wav
+
+
+ Pacifico.ttf
+
+
+ LL-171A-B-B797E457-16AB-C708-1E0F-32C19DBD47B5.icc
+
+
+ drum01.mp3
+
+
+ Model3.arobject
+
+
+ access-denied.html
+
+
+ access-granted.html
+
+
+
+
+
+
+
+
+
+
+ CoreImage\Xam.png
+
+
+ Resources\xamarin0.png
+
+
+ Resources\xamarin1.png
+
+
+ Resources\xamarin2.png
+
+
+ xamvideotest.mp4
+
+
+ CoreImage\xamarinmonkey.heic
+
+
+ Resources\Base.lproj\Localizable.strings
+
+
+ Resources\metal-sample.metal
+
+
+ Resources\fragmentShader.metal
+
+
+ uncompressed.txt
+
+
+ compressed_lze
+
+
+ compressed_lz4
+
+
+ compressed_lzma
+
+
+ compressed_zip
+
+
+ example.pac
+
+
+ Resources\square.gif
+
+
+
+
+ Resources\metal-sample.metal
+
+
+
+
+ monotouchtest.Security.openssl_crt.der
+
+
+
+
+ ..\..\..\..\tests\test-libraries
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ <_SmeltingSdk Condition="'$(_PlatformName)' == 'iOS'">iphoneos
+ <_SmeltingSdk Condition="'$(_PlatformName)' == 'tvOS'">appletvos
+ <_SmeltingMinOS Condition="'$(_PlatformName)' == 'iOS'">-mios-version-min=11.0
+ <_SmeltingMinOS Condition="'$(_PlatformName)' == 'tvOS'">-mtvos-version-min=11.0
+
+
+
+
+
+
+
+
+
+
+
diff --git a/tests/xharness/Harness.cs b/tests/xharness/Harness.cs
index e2bba3fe29..f1a43545e1 100644
--- a/tests/xharness/Harness.cs
+++ b/tests/xharness/Harness.cs
@@ -297,6 +297,13 @@ namespace Xharness {
Platform = "AnyCPU",
});
+ MacTestProjects.Add (new MacTestProject (Path.GetFullPath (Path.Combine (RootDirectory, "monotouch-test", "dotnet", "MacCatalyst", "monotouch-test.csproj"))) {
+ Name = "monotouch-test",
+ IsDotNetProject = true,
+ TargetFrameworkFlavors = MacFlavors.MacCatalyst,
+ Platform = "AnyCPU",
+ });
+
foreach (var flavor in new MonoNativeFlavor [] { MonoNativeFlavor.Compat, MonoNativeFlavor.Unified }) {
var monoNativeInfo = new MonoNativeInfo (DevicePlatform.macOS, flavor, RootDirectory, Log);
var macTestProject = new MacTestProject (monoNativeInfo.ProjectPath, targetFrameworkFlavor: MacFlavors.Modern | MacFlavors.Full) {
@@ -413,7 +420,7 @@ namespace Xharness {
IOSTestProjects.Add (new iOSTestProject (Path.GetFullPath (Path.Combine (RootDirectory, "introspection", "iOS", "introspection-ios.csproj"))) { Name = "introspection", IgnoreMacCatalystVariation = false });
IOSTestProjects.Add (new iOSTestProject (Path.GetFullPath (Path.Combine (RootDirectory, "introspection", "dotnet", "iOS", "introspection.csproj"))) { Name = "introspection", IsDotNetProject = true, SkipiOSVariation = false, SkiptvOSVariation = true, SkipwatchOSVariation = true, SkipTodayExtensionVariation = true, SkipDeviceVariations = false, SkipiOS32Variation = true, });
IOSTestProjects.Add (new iOSTestProject (Path.GetFullPath (Path.Combine (RootDirectory, "introspection", "dotnet", "tvOS", "introspection.csproj"))) { Name = "introspection", IsDotNetProject = true, SkipiOSVariation = true, SkiptvOSVariation = true, SkipwatchOSVariation = true, SkipTodayExtensionVariation = true, SkipDeviceVariations = false, SkipiOS32Variation = true, GenerateVariations = false, TestPlatform = TestPlatform.tvOS, });
- IOSTestProjects.Add (new iOSTestProject (Path.GetFullPath (Path.Combine (RootDirectory, "monotouch-test", "dotnet", "iOS", "monotouch-test.csproj"))) { Name = "monotouch-test", IsDotNetProject = true, SkipiOSVariation = false, SkiptvOSVariation = true, SkipwatchOSVariation = true, SkipTodayExtensionVariation = true, SkipDeviceVariations = false, SkipiOS32Variation = true, IgnoreMacCatalystVariation = true });
+ IOSTestProjects.Add (new iOSTestProject (Path.GetFullPath (Path.Combine (RootDirectory, "monotouch-test", "dotnet", "iOS", "monotouch-test.csproj"))) { Name = "monotouch-test", IsDotNetProject = true, SkipiOSVariation = false, SkiptvOSVariation = true, SkipwatchOSVariation = true, SkipTodayExtensionVariation = true, SkipDeviceVariations = false, SkipiOS32Variation = true, GenerateVariations = false, TestPlatform = TestPlatform.iOS_Unified, });
IOSTestProjects.Add (new iOSTestProject (Path.GetFullPath (Path.Combine (RootDirectory, "monotouch-test", "dotnet", "tvOS", "monotouch-test.csproj"))) { Name = "monotouch-test", IsDotNetProject = true, SkipiOSVariation = true, SkiptvOSVariation = true, SkipwatchOSVariation = true, SkipTodayExtensionVariation = true, SkipDeviceVariations = false, SkipiOS32Variation = true, GenerateVariations = false, TestPlatform = TestPlatform.tvOS, });
IOSTestProjects.Add (new iOSTestProject (Path.GetFullPath (Path.Combine (RootDirectory, "linker", "ios", "dont link", "dont link.csproj"))) {
Configurations = new string [] { "Debug", "Release" },
diff --git a/tests/xharness/Jenkins/TestVariationsFactory.cs b/tests/xharness/Jenkins/TestVariationsFactory.cs
index f6e23aea29..03460f8af7 100644
--- a/tests/xharness/Jenkins/TestVariationsFactory.cs
+++ b/tests/xharness/Jenkins/TestVariationsFactory.cs
@@ -33,6 +33,13 @@ namespace Xharness.Jenkins {
var supports_dynamic_registrar_on_device = test.Platform == TestPlatform.iOS_Unified64 || test.Platform == TestPlatform.tvOS;
var ignore = test.TestProject.Ignore;
var mac_supports_arm64 = Harness.CanRunArm64;
+ var arm64_runtime_identifier = string.Empty;
+
+ if (test.Platform == TestPlatform.Mac) {
+ arm64_runtime_identifier = "osx-arm64";
+ } else if (test.Platform == TestPlatform.MacCatalyst) {
+ arm64_runtime_identifier = "maccatalyst-arm64";
+ }
switch (test.ProjectPlatform) {
case "iPhone":
@@ -119,9 +126,11 @@ namespace Xharness.Jenkins {
case "monotouch-test":
if (test.TestProject.IsDotNetProject) {
var isDotNetReady = false;
- yield return new TestData { Variation = "Debug (CoreCLR)", Debug = true, UseMonoRuntime = false, Ignored = !isDotNetReady || !jenkins.IncludeMac, };
- yield return new TestData { Variation = "Debug (ARM64)", Debug = true, Profiling = false, Ignored = !isDotNetReady || !jenkins.IncludeMac || !mac_supports_arm64, RuntimeIdentifier = "osx-arm64", };
- yield return new TestData { Variation = "Debug (CoreCLR, ARM64)", Debug = true, UseMonoRuntime = false, Profiling = false, Ignored = !isDotNetReady || !jenkins.IncludeMac || !mac_supports_arm64, RuntimeIdentifier = "osx-arm64", };
+ if (test.Platform != TestPlatform.MacCatalyst)
+ yield return new TestData { Variation = "Debug (CoreCLR)", Debug = true, UseMonoRuntime = false, Ignored = !isDotNetReady || !jenkins.IncludeMac, };
+ yield return new TestData { Variation = "Debug (ARM64)", Debug = true, Profiling = false, Ignored = !isDotNetReady || !jenkins.IncludeMac || !mac_supports_arm64, RuntimeIdentifier = arm64_runtime_identifier, };
+ if (test.Platform != TestPlatform.MacCatalyst)
+ yield return new TestData { Variation = "Debug (CoreCLR, ARM64)", Debug = true, UseMonoRuntime = false, Profiling = false, Ignored = !isDotNetReady || !jenkins.IncludeMac || !mac_supports_arm64, RuntimeIdentifier = arm64_runtime_identifier, };
}
break;
case "xammac tests":
diff --git a/tests/xharness/MacFlavorsExtensions.cs b/tests/xharness/MacFlavorsExtensions.cs
index 822d0281d8..a46c8388d2 100644
--- a/tests/xharness/MacFlavorsExtensions.cs
+++ b/tests/xharness/MacFlavorsExtensions.cs
@@ -13,6 +13,7 @@ namespace Xharness {
MacFlavors.Modern => TestPlatform.Mac_Modern,
MacFlavors.System => TestPlatform.Mac_System,
MacFlavors.DotNet => TestPlatform.Mac,
+ MacFlavors.MacCatalyst => TestPlatform.MacCatalyst,
_ => throw new NotImplementedException (flavor.ToString ()),
};
}
diff --git a/tests/xharness/MacTestProject.cs b/tests/xharness/MacTestProject.cs
index 3f17967d3d..86477ffee3 100644
--- a/tests/xharness/MacTestProject.cs
+++ b/tests/xharness/MacTestProject.cs
@@ -8,6 +8,7 @@ namespace Xharness {
System = 4, // Xamarin.Mac/System app
Console = 8, // Console executable
DotNet = 16,
+ MacCatalyst = 32,
}
public class MacTestProject : TestProject {