IEnumerable <TestData> GetTestData(RunTestTask test)
        {
            // This function returns additional test configurations (in addition to the default one) for the specific test

            // 32-bit interpreter doesn't work yet: https://github.com/mono/mono/issues/9871
            var supports_interpreter = test.Platform != TestPlatform.iOS_Unified32;
            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":
                // arm64_32 is only supported for Release builds for now.
                // arm32 bits too big for debug builds - https://github.com/xamarin/maccore/issues/2080
                var supports_debug = test.Platform != TestPlatform.watchOS_64_32 && !(test.TestName == "dont link" && test.Platform == TestPlatform.iOS_Unified32);

                /* we don't add --assembly-build-target=@all=staticobject because that's the default in all our test projects */
                if (supports_debug && !test.TestProject.IsDotNetProject)
                {
                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: dylib (debug)", MTouchExtraArgs = $"--assembly-build-target=@all=dynamiclibrary {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Dynamic, Ignored = ignore
                    });

                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: SDK framework (debug)", MTouchExtraArgs = $"--assembly-build-target=@sdk=framework=Xamarin.Sdk --assembly-build-target=@all=staticobject {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, Ignored = ignore
                    });

                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: dylib (debug, profiling)", MTouchExtraArgs = $"--assembly-build-target=@all=dynamiclibrary {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = true, MonoNativeLinkMode = MonoNativeLinkMode.Dynamic, Ignored = ignore
                    });

                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: SDK framework (debug, profiling)", MTouchExtraArgs = $"--assembly-build-target=@sdk=framework=Xamarin.Sdk --assembly-build-target=@all=staticobject {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = true, MonoNativeLinkMode = MonoNativeLinkMode.Static, Ignored = ignore
                    });
                }

                if (test.ProjectConfiguration.Contains("Debug"))
                {
                    yield return new TestData {
                               Variation = "Release", MTouchExtraArgs = test.TestProject.MTouchExtraArgs, Debug = false, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static
                    }
                }
                ;
                if (test.Platform == TestPlatform.iOS_Unified32 && !test.TestProject.IsDotNetProject)
                {
                    yield return new TestData {
                               Variation = "Release: UseThumb", MTouchExtraArgs = test.TestProject.MTouchExtraArgs, Debug = false, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, UseThumb = true
                    }
                }
                ;

                // Disable this by default for tvOS/Release because the app ends up being too big (https://github.com/xamarin/maccore/issues/2282)
                var sdk_release_skip = test.Platform == TestPlatform.tvOS && test.TestName == "dont link";
                sdk_release_skip = sdk_release_skip || test.TestProject.IsDotNetProject;
                if (!sdk_release_skip)
                {
                    yield return new TestData {
                               Variation = "AssemblyBuildTarget: SDK framework (release)", MTouchExtraArgs = $"--assembly-build-target=@sdk=framework=Xamarin.Sdk --assembly-build-target=@all=staticobject {test.TestProject.MTouchExtraArgs}", Debug = false, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static,
                    }
                }
                ;

                switch (test.TestName)
                {
                case "monotouch-test":
                    if (test.TestProject.IsDotNetProject)
                    {
                        ignore = true;
                    }
                    if (supports_dynamic_registrar_on_device)
                    {
                        yield return new TestData {
                                   Variation = "Debug (dynamic registrar)", MTouchExtraArgs = "--registrar:dynamic", Debug = true, Profiling = false, Ignored = ignore
                        }
                    }
                    ;

                    yield return(new TestData {
                        Variation = "Release (all optimizations)", MTouchExtraArgs = "--registrar:static --optimize:all", Debug = false, Profiling = false, Defines = "OPTIMIZEALL", Ignored = ignore
                    });

                    if (supports_debug)
                    {
                        yield return(new TestData {
                            Variation = "Debug (all optimizations)", MTouchExtraArgs = "--registrar:static --optimize:all", Debug = true, Profiling = false, Defines = "OPTIMIZEALL", Ignored = ignore
                        });

                        yield return(new TestData {
                            Variation = "Debug: SGenConc", MTouchExtraArgs = "", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, EnableSGenConc = true, Ignored = ignore
                        });
                    }
                    if (supports_interpreter)
                    {
                        if (supports_debug)
                        {
                            yield return(new TestData {
                                Variation = "Debug (interpreter)", MTouchExtraArgs = "--interpreter", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME", Ignored = ignore
                            });

                            yield return(new TestData {
                                Variation = "Debug (interpreter -mscorlib)", MTouchExtraArgs = "--interpreter=-mscorlib", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME", Ignored = ignore
                            });
                        }
                        yield return(new TestData {
                            Variation = "Release (interpreter -mscorlib)", MTouchExtraArgs = "--interpreter=-mscorlib", Debug = false, Profiling = false, Undefines = "FULL_AOT_RUNTIME", Ignored = ignore
                        });
                    }
                    if (test.TestProject.IsDotNetProject)
                    {
                        yield return new TestData {
                                   Variation = "Release (LLVM)", Debug = false, UseLlvm = true, Ignored = ignore
                        }
                    }
                    ;
                    break;

                case  string name when name.StartsWith("mscorlib", StringComparison.Ordinal):
                    if (supports_debug)
                    {
                        yield return new TestData {
                                   Variation = "Debug: SGenConc", MTouchExtraArgs = "", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, EnableSGenConc = true
                        }
                    }
                    ;

                    if (supports_interpreter)
                    {
                        if (supports_debug)
                        {
                            yield return(new TestData {
                                Variation = "Debug (interpreter)", MTouchExtraArgs = "--interpreter", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME", KnownFailure = (HumanMessage : "#1683", IssueLink : "https://github.com/xamarin/maccore/issues/1683")
                            });

                            yield return(new TestData {
                                Variation = "Debug (interpreter -mscorlib)", MTouchExtraArgs = "--interpreter=-mscorlib", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME", KnownFailure = (HumanMessage : "#1682", IssueLink : "https://github.com/xamarin/maccore/issues/1682")
                            });
                        }
Exemple #2
0
        IEnumerable <TestData> GetTestData(RunTestTask test)
        {
            // This function returns additional test configurations (in addition to the default one) for the specific test

            MonoNativeFlavor flavor;

            switch (test.TestName)
            {
            case "mono-native-compat":
                flavor = MonoNativeFlavor.Compat;
                break;

            case "mono-native-unified":
                flavor = MonoNativeFlavor.Unified;
                break;

            default:
                flavor = MonoNativeFlavor.None;
                break;
            }

            // 32-bit interpreter doesn't work yet: https://github.com/mono/mono/issues/9871
            var supports_interpreter = test.Platform != TestPlatform.iOS_Unified32;
            var supports_dynamic_registrar_on_device = test.Platform == TestPlatform.iOS_Unified64 || test.Platform == TestPlatform.tvOS;

            switch (test.ProjectPlatform)
            {
            case "iPhone":
                // arm64_32 is only supported for Release builds for now.
                // arm32 bits too big for debug builds - https://github.com/xamarin/maccore/issues/2080
                var supports_debug = test.Platform != TestPlatform.watchOS_64_32 && !(test.TestName == "dont link" && test.Platform == TestPlatform.iOS_Unified32);

                /* we don't add --assembly-build-target=@all=staticobject because that's the default in all our test projects */
                if (supports_debug)
                {
                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: dylib (debug)", MTouchExtraArgs = $"--assembly-build-target=@all=dynamiclibrary {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Dynamic, MonoNativeFlavor = flavor
                    });

                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: SDK framework (debug)", MTouchExtraArgs = $"--assembly-build-target=@sdk=framework=Xamarin.Sdk --assembly-build-target=@all=staticobject {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, MonoNativeFlavor = flavor
                    });

                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: dylib (debug, profiling)", MTouchExtraArgs = $"--assembly-build-target=@all=dynamiclibrary {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = true, MonoNativeLinkMode = MonoNativeLinkMode.Dynamic, MonoNativeFlavor = flavor
                    });

                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: SDK framework (debug, profiling)", MTouchExtraArgs = $"--assembly-build-target=@sdk=framework=Xamarin.Sdk --assembly-build-target=@all=staticobject {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = true, MonoNativeLinkMode = MonoNativeLinkMode.Static, MonoNativeFlavor = flavor
                    });
                }

                if (test.ProjectConfiguration.Contains("Debug"))
                {
                    yield return new TestData {
                               Variation = "Release", MTouchExtraArgs = test.TestProject.MTouchExtraArgs, Debug = false, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static
                    }
                }
                ;
                if (test.Platform == TestPlatform.iOS_Unified32)
                {
                    yield return new TestData {
                               Variation = "Release: UseThumb", MTouchExtraArgs = test.TestProject.MTouchExtraArgs, Debug = false, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, UseThumb = true
                    }
                }
                ;
                yield return(new TestData {
                    Variation = "AssemblyBuildTarget: SDK framework (release)", MTouchExtraArgs = $"--assembly-build-target=@sdk=framework=Xamarin.Sdk --assembly-build-target=@all=staticobject {test.TestProject.MTouchExtraArgs}", Debug = false, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, MonoNativeFlavor = flavor
                });

                switch (test.TestName)
                {
                case "monotouch-test":
                    if (supports_dynamic_registrar_on_device)
                    {
                        yield return new TestData {
                                   Variation = "Debug (dynamic registrar)", MTouchExtraArgs = "--registrar:dynamic", Debug = true, Profiling = false
                        }
                    }
                    ;

                    yield return(new TestData {
                        Variation = "Release (all optimizations)", MTouchExtraArgs = "--registrar:static --optimize:all", Debug = false, Profiling = false, Defines = "OPTIMIZEALL"
                    });

                    if (supports_debug)
                    {
                        yield return(new TestData {
                            Variation = "Debug (all optimizations)", MTouchExtraArgs = "--registrar:static --optimize:all", Debug = true, Profiling = false, Defines = "OPTIMIZEALL"
                        });

                        yield return(new TestData {
                            Variation = "Debug: SGenConc", MTouchExtraArgs = "", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, EnableSGenConc = true
                        });
                    }
                    if (supports_interpreter)
                    {
                        if (supports_debug)
                        {
                            yield return(new TestData {
                                Variation = "Debug (interpreter)", MTouchExtraArgs = "--interpreter", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME"
                            });

                            yield return(new TestData {
                                Variation = "Debug (interpreter -mscorlib)", MTouchExtraArgs = "--interpreter=-mscorlib", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME"
                            });
                        }
                        yield return(new TestData {
                            Variation = "Release (interpreter -mscorlib)", MTouchExtraArgs = "--interpreter=-mscorlib", Debug = false, Profiling = false, Undefines = "FULL_AOT_RUNTIME"
                        });
                    }
                    break;

                case  string name when name.StartsWith("mscorlib", StringComparison.Ordinal):
                    if (supports_debug)
                    {
                        yield return new TestData {
                                   Variation = "Debug: SGenConc", MTouchExtraArgs = "", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, EnableSGenConc = true
                        }
                    }
                    ;

                    if (supports_interpreter)
                    {
                        if (supports_debug)
                        {
                            yield return(new TestData {
                                Variation = "Debug (interpreter)", MTouchExtraArgs = "--interpreter", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME", KnownFailure = (HumanMessage : "#1683", IssueLink : "https://github.com/xamarin/maccore/issues/1683")
                            });

                            yield return(new TestData {
                                Variation = "Debug (interpreter -mscorlib)", MTouchExtraArgs = "--interpreter=-mscorlib", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME", KnownFailure = (HumanMessage : "#1682", IssueLink : "https://github.com/xamarin/maccore/issues/1682")
                            });
                        }
Exemple #3
0
        IEnumerable <TestData> GetTestData(RunTestTask test)
        {
            // This function returns additional test configurations (in addition to the default one) for the specific test

            // 32-bit interpreter doesn't work yet: https://github.com/mono/mono/issues/9871
            var supports_interpreter = test.Platform != TestPlatform.iOS_Unified32;
            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;
            var arm64_sim_runtime_identifier = string.Empty;

            switch (test.Platform)
            {
            case TestPlatform.Mac:
                arm64_runtime_identifier = "osx-arm64";
                break;

            case TestPlatform.MacCatalyst:
                arm64_runtime_identifier = "maccatalyst-arm64";
                break;

            case TestPlatform.iOS:
            case TestPlatform.iOS_Unified:
                arm64_sim_runtime_identifier = "iossimulator-arm64";
                break;

            case TestPlatform.tvOS:
                arm64_sim_runtime_identifier = "tvossimulator-arm64";
                break;
            }

            switch (test.ProjectPlatform)
            {
            case "iPhone":
                // arm64_32 is only supported for Release builds for now.
                // arm32 bits too big for debug builds - https://github.com/xamarin/maccore/issues/2080
                var supports_debug = test.Platform != TestPlatform.watchOS_64_32 && !(test.TestName == "dont link" && test.Platform == TestPlatform.iOS_Unified32);

                /* we don't add --assembly-build-target=@all=staticobject because that's the default in all our test projects */
                if (supports_debug && !test.TestProject.IsDotNetProject)
                {
                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: dylib (debug)", MTouchExtraArgs = $"--assembly-build-target=@all=dynamiclibrary {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Dynamic, Ignored = ignore
                    });

                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: SDK framework (debug)", MTouchExtraArgs = $"--assembly-build-target=@sdk=framework=Xamarin.Sdk --assembly-build-target=@all=staticobject {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, Ignored = ignore
                    });

                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: dylib (debug, profiling)", MTouchExtraArgs = $"--assembly-build-target=@all=dynamiclibrary {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = true, MonoNativeLinkMode = MonoNativeLinkMode.Dynamic, Ignored = ignore
                    });

                    yield return(new TestData {
                        Variation = "AssemblyBuildTarget: SDK framework (debug, profiling)", MTouchExtraArgs = $"--assembly-build-target=@sdk=framework=Xamarin.Sdk --assembly-build-target=@all=staticobject {test.TestProject.MTouchExtraArgs}", Debug = true, Profiling = true, MonoNativeLinkMode = MonoNativeLinkMode.Static, Ignored = ignore
                    });
                }

                if (test.ProjectConfiguration.Contains("Debug"))
                {
                    yield return new TestData {
                               Variation = "Release", MTouchExtraArgs = test.TestProject.MTouchExtraArgs, Debug = false, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static
                    }
                }
                ;
                if (test.Platform == TestPlatform.iOS_Unified32 && !test.TestProject.IsDotNetProject)
                {
                    yield return new TestData {
                               Variation = "Release: UseThumb", MTouchExtraArgs = test.TestProject.MTouchExtraArgs, Debug = false, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, UseThumb = true
                    }
                }
                ;

                // Disable this by default for tvOS/Release because the app ends up being too big (https://github.com/xamarin/maccore/issues/2282)
                var sdk_release_skip = test.Platform == TestPlatform.tvOS && test.TestName == "dont link";
                sdk_release_skip = sdk_release_skip || test.TestProject.IsDotNetProject;
                if (!sdk_release_skip)
                {
                    yield return new TestData {
                               Variation = "AssemblyBuildTarget: SDK framework (release)", MTouchExtraArgs = $"--assembly-build-target=@sdk=framework=Xamarin.Sdk --assembly-build-target=@all=staticobject {test.TestProject.MTouchExtraArgs}", Debug = false, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static,
                    }
                }
                ;

                switch (test.TestName)
                {
                case "monotouch-test":
                    if (test.TestProject.IsDotNetProject)
                    {
                        ignore = true;
                    }
                    if (supports_dynamic_registrar_on_device)
                    {
                        yield return new TestData {
                                   Variation = "Debug (dynamic registrar)", MTouchExtraArgs = "--registrar:dynamic", Debug = true, Profiling = false, Ignored = ignore
                        }
                    }
                    ;

                    yield return(new TestData {
                        Variation = "Release (all optimizations)", MTouchExtraArgs = "--registrar:static --optimize:all", Debug = false, Profiling = false, Defines = "OPTIMIZEALL", Ignored = ignore
                    });

                    if (supports_debug)
                    {
                        yield return(new TestData {
                            Variation = "Debug (all optimizations)", MTouchExtraArgs = "--registrar:static --optimize:all", Debug = true, Profiling = false, Defines = "OPTIMIZEALL", Ignored = ignore
                        });

                        yield return(new TestData {
                            Variation = "Debug: SGenConc", MTouchExtraArgs = "", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, EnableSGenConc = true, Ignored = ignore
                        });
                    }
                    if (supports_interpreter)
                    {
                        if (supports_debug)
                        {
                            yield return(new TestData {
                                Variation = "Debug (interpreter)", MTouchExtraArgs = "--interpreter", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME", Ignored = ignore
                            });

                            yield return(new TestData {
                                Variation = "Debug (interpreter -mscorlib)", MTouchExtraArgs = "--interpreter=-mscorlib", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME", Ignored = ignore
                            });
                        }
                        yield return(new TestData {
                            Variation = "Release (interpreter -mscorlib)", MTouchExtraArgs = "--interpreter=-mscorlib", Debug = false, Profiling = false, Undefines = "FULL_AOT_RUNTIME", Ignored = ignore
                        });
                    }
                    if (test.TestProject.IsDotNetProject)
                    {
                        yield return new TestData {
                                   Variation = "Release (LLVM)", Debug = false, UseLlvm = true, Ignored = ignore
                        }
                    }
                    ;
                    break;

                case  string name when name.StartsWith("mscorlib", StringComparison.Ordinal):
                    if (supports_debug)
                    {
                        yield return new TestData {
                                   Variation = "Debug: SGenConc", MTouchExtraArgs = "", Debug = true, Profiling = false, MonoNativeLinkMode = MonoNativeLinkMode.Static, EnableSGenConc = true
                        }
                    }
                    ;

                    if (supports_interpreter)
                    {
                        if (supports_debug)
                        {
                            yield return(new TestData {
                                Variation = "Debug (interpreter)", MTouchExtraArgs = "--interpreter", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME", KnownFailure = new KnownIssue("#1683", issueLink: "https://github.com/xamarin/maccore/issues/1683")
                            });

                            yield return(new TestData {
                                Variation = "Debug (interpreter -mscorlib)", MTouchExtraArgs = "--interpreter=-mscorlib", Debug = true, Profiling = false, Undefines = "FULL_AOT_RUNTIME", KnownFailure = new KnownIssue("#1682", issueLink: "https://github.com/xamarin/maccore/issues/1682")
                            });
                        }
                        yield return(new TestData {
                            Variation = "Release (interpreter -mscorlib)", MTouchExtraArgs = "--interpreter=-mscorlib", Debug = false, Profiling = false, Undefines = "FULL_AOT_RUNTIME", KnownFailure = new KnownIssue("#1682", issueLink: "https://github.com/xamarin/maccore/issues/1682")
                        });
                    }
                    break;
                }
                break;

            case "iPhoneSimulator":
                if (test.Platform == TestPlatform.iOS_Unified32)
                {
                    ignore = true;
                }

                switch (test.TestName)
                {
                case "monotouch-test":
                    // The default is to run monotouch-test with the dynamic registrar (in the simulator), so that's already covered
                    yield return(new TestData {
                        Variation = "Debug (LinkSdk)", Debug = true, Profiling = false, LinkMode = test.TestProject.IsDotNetProject ? "SdkOnly" : "LinkSdk", Ignored = ignore
                    });

                    yield return(new TestData {
                        Variation = "Debug (static registrar)", MTouchExtraArgs = "--registrar:static", Debug = true, Profiling = false, Undefines = "DYNAMIC_REGISTRAR", Ignored = ignore
                    });

                    yield return(new TestData {
                        Variation = "Release (all optimizations)", MTouchExtraArgs = "--registrar:static --optimize:all", Debug = false, Profiling = false, LinkMode = "Full", Defines = "OPTIMIZEALL", Undefines = "DYNAMIC_REGISTRAR", Ignored = ignore
                    });

                    yield return(new TestData {
                        Variation = "Debug (all optimizations)", MTouchExtraArgs = "--registrar:static --optimize:all,-remove-uithread-checks", Debug = true, Profiling = false, LinkMode = "Full", Defines = "OPTIMIZEALL", Undefines = "DYNAMIC_REGISTRAR", Ignored = ignore ?? !jenkins.IncludeAll
                    });

                    if (test.TestProject.IsDotNetProject && mac_supports_arm64)
                    {
                        yield return new TestData {
                                   Variation = "Debug (ARM64)", Debug = true, Profiling = false, Ignored = !mac_supports_arm64 ? true : ignore, RuntimeIdentifier = arm64_sim_runtime_identifier,
                        }
                    }
                    ;
                    break;

                case "introspection":
                    if (test.TestProject.IsDotNetProject && mac_supports_arm64)
                    {
                        yield return new TestData {
                                   Variation = "Debug (ARM64)", Debug = true, Profiling = false, Ignored = !mac_supports_arm64 ? true : ignore, RuntimeIdentifier = arm64_sim_runtime_identifier,
                        }
                    }
                    ;

                    foreach (var target in test.Platform.GetAppRunnerTargets())
                    {
                        yield return new TestData {
                                   Variation  = $"Debug ({test.Platform.GetSimulatorMinVersion ()})",
                                   Debug      = true,
                                   Candidates = jenkins.Simulators.SelectDevices(target.GetTargetOs(true), jenkins.SimulatorLoadLog, true),
                                   Ignored    = ignore ?? !jenkins.IncludeOldSimulatorTests,
                        }
                    }
                    ;
                    break;
                }
                break;

            case "AnyCPU":
            case "x86":
                switch (test.TestName)
                {
                case "monotouch-test":
                    if (test.TestProject.IsDotNetProject)
                    {
                        yield return(new TestData {
                            Variation = "Debug (ARM64)", Debug = true, Profiling = false, Ignored = !jenkins.IncludeMac || !mac_supports_arm64, RuntimeIdentifier = arm64_runtime_identifier,
                        });

                        if (test.Platform != TestPlatform.MacCatalyst)
                        {
                            yield return(new TestData {
                                Variation = "Debug (static registrar)", MonoBundlingExtraArgs = "--registrar:static", Debug = true, Undefines = "DYNAMIC_REGISTRAR", Ignored = !jenkins.IncludeMac,
                            });

                            yield return(new TestData {
                                Variation = "Debug (static registrar, ARM64)", MonoBundlingExtraArgs = "--registrar:static", Debug = true, Undefines = "DYNAMIC_REGISTRAR", Profiling = false, Ignored = !jenkins.IncludeMac || !mac_supports_arm64, RuntimeIdentifier = arm64_runtime_identifier,
                            });
                        }
                        if (test.Platform == TestPlatform.MacCatalyst)
                        {
                            yield return new TestData {
                                       Variation = "Release (ARM64, LLVM)", Debug = false, UseLlvm = true, Ignored = !jenkins.IncludeMacCatalyst || !mac_supports_arm64, RuntimeIdentifier = arm64_runtime_identifier
                            }
                        }
                        ;
                    }
                    break;

                case "xammac tests":
                    switch (test.ProjectConfiguration)
                    {
                    case "Release":
                        yield return(new TestData {
                            Variation = "Release (all optimizations)", MonoBundlingExtraArgs = "--registrar:static --optimize:all", Debug = false, LinkMode = "Full", Defines = "OPTIMIZEALL", Undefines = "DYNAMIC_REGISTRAR"
                        });

                        yield return(new TestData {
                            Variation = "Release (ARM64)", XamMacArch = "ARM64", Debug = false, Ignored = !mac_supports_arm64 || !jenkins.IncludeMac
                        });

                        break;

                    case "Debug":
                        yield return(new TestData {
                            Variation = "Debug (all optimizations)", MonoBundlingExtraArgs = "--registrar:static --optimize:all,-remove-uithread-checks", Debug = true, LinkMode = "Full", Defines = "OPTIMIZEALL", Undefines = "DYNAMIC_REGISTRAR", Ignored = !(jenkins.IncludeAll && jenkins.IncludeMac)
                        });

                        yield return(new TestData {
                            Variation = "Debug (ARM64)", XamMacArch = "ARM64", Debug = true, Ignored = !mac_supports_arm64 || !jenkins.IncludeMac
                        });

                        break;
                    }
                    break;
                }
                break;

            default:
                throw new NotImplementedException(test.ProjectPlatform);
            }
        }