Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
19 commits
Select commit Hold shift + click to select a range
2cfff87
[CI] Use ACES for CI builds
dalexsoto May 27, 2026
99e2604
[CI] Use ACES for CI API Diff
dalexsoto May 27, 2026
a98508a
[CI] Run CI simulator tests on ACES
dalexsoto May 27, 2026
cf6bde1
[CI] Prepare PR chain pipelines for future ACES use
dalexsoto May 27, 2026
9446c3f
[CI] Create a global ACES switch for PR and CI builds
dalexsoto May 27, 2026
436e9bb
Merge remote-tracking branch 'origin/main' into release-test/use-aces
dalexsoto May 27, 2026
18ef1a8
[Tests] Fix SpecialFolder tests on macOS CI VMs
dalexsoto May 28, 2026
60feeed
[Tests] remove retry in order to get results from CI monotouch-tests run
dalexsoto May 28, 2026
c58dfa2
[CI] Fix global usage of UseACES_XX
dalexsoto May 28, 2026
ae929aa
[CI] Unfortunately no global switch so going back to docs and switches
dalexsoto May 28, 2026
cb53e40
[CI] onboard Build macOS tests into ACES too
dalexsoto May 28, 2026
8489ece
[CI] Fix monotouch-tests by propagating that we are running under a V…
dalexsoto May 28, 2026
ae01ef1
Merge remote-tracking branch 'origin/main' into release-test/use-aces
dalexsoto May 28, 2026
c0475b0
[tests] A couple of more VM checks on VideoToolbox
dalexsoto May 28, 2026
541d5bf
[CI] Retry the provisioning if it fails
dalexsoto May 28, 2026
c9f4987
[Tests] bring back retry on tests
dalexsoto May 29, 2026
1adb358
[tests] refine CI-only tolerance check for user directories in LinkSd…
dalexsoto May 29, 2026
23cc6fc
Merge branch 'main' into release-test/use-aces
dalexsoto Jun 1, 2026
a6425cb
[tests] Revert to https and disable retry to diagnose furrther
dalexsoto Jun 1, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions tests/common/TestRuntime.cs
Original file line number Diff line number Diff line change
Expand Up @@ -299,12 +299,10 @@ public static void AssertSimulatorOrDesktop (string message = "This test only wo

public static void AssertNotVirtualMachine ()
{
#if MONOMAC || __MACCATALYST__
// enviroment variable set by the CI when running on a VM
var vmVendor = Environment.GetEnvironmentVariable ("VM_VENDOR");
if (!string.IsNullOrEmpty (vmVendor))
NUnit.Framework.Assert.Ignore ($"This test only runs on device. Found vm vendor: {vmVendor}");
#endif
}

public static bool IsVSTS =>
Expand Down
19 changes: 15 additions & 4 deletions tests/linker/link sdk/LinkSdkRegressionTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -789,11 +789,11 @@ void SpecialFolderImpl ()
#else
var myExists = false;
#endif
path = TestFolder (Environment.SpecialFolder.MyMusic, exists: myExists);
path = TestFolderIfAvailableInCI (Environment.SpecialFolder.MyMusic, myExists);

path = TestFolder (Environment.SpecialFolder.MyVideos, exists: myExists);
path = TestFolderIfAvailableInCI (Environment.SpecialFolder.MyVideos, myExists);

path = TestFolder (Environment.SpecialFolder.DesktopDirectory, exists: myExists);
path = TestFolderIfAvailableInCI (Environment.SpecialFolder.DesktopDirectory, myExists);

#if __TVOS__
path = TestFolder (Environment.SpecialFolder.Fonts, exists: null, supported: true);
Expand All @@ -811,7 +811,7 @@ void SpecialFolderImpl ()
path = TestFolder (Environment.SpecialFolder.Templates, exists: false);
#endif

path = TestFolder (Environment.SpecialFolder.MyPictures, exists: myExists);
path = TestFolderIfAvailableInCI (Environment.SpecialFolder.MyPictures, myExists);

#if __MACOS__
path = TestFolder (Environment.SpecialFolder.CommonTemplates, supported: false);
Expand Down Expand Up @@ -897,6 +897,17 @@ void SpecialFolderImpl ()
path = TestFolder (Environment.SpecialFolder.Resources, readOnly: tvos && device);
Assert.That (path.EndsWith ("/Library", StringComparison.Ordinal), Is.True, "Resources");
#endif
// Some CI VM images don't initialize all standard user directories, so keep this
// tolerance limited to CI VMs and preserve the stricter check for other runs.
string TestFolderIfAvailableInCI (Environment.SpecialFolder folder, bool exists)
Comment thread
rolfbjarne marked this conversation as resolved.
{
#if __MACOS__
var path = Environment.GetFolderPath (folder);
if (string.IsNullOrEmpty (path) && TestRuntime.IsInCI && TestRuntime.IsVM)
return path;
#endif
return TestFolder (folder, exists: exists);
}
}

#if !__MACOS__
Expand Down
2 changes: 2 additions & 0 deletions tests/monotouch-test/AudioToolbox/AudioQueueTest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,8 @@ public void Properties ()
[Test]
public void ChannelAssignments ()
{
TestRuntime.AssertNotVirtualMachine ();

var aq = new OutputAudioQueue (AudioStreamBasicDescription.CreateLinearPCM ());

var route = global::AVFoundation.AVAudioSession.SharedInstance ().CurrentRoute;
Expand Down
2 changes: 2 additions & 0 deletions tests/monotouch-test/Metal/MTLDeviceTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,8 @@ public void ReturnReleaseTest ()
if (device is null)
Assert.Inconclusive ("Metal is not supported");

TestRuntime.AssertNotVirtualMachine ();

// Apple claims that "Indirect command buffers" are available with MTLGPUFamilyCommon2, but it crashes on at least one machine.
// Log what the current device supports, just to have it in the log.
foreach (MTLFeatureSet fs in Enum.GetValues<MTLFeatureSet> ()) {
Expand Down
1 change: 1 addition & 0 deletions tests/monotouch-test/System.Net.Http/NetworkResources.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ public static class NetworkResources {
public static string MicrosoftUrl => AssertNetworkConnection ("https://www.microsoft.com");
public static Uri MicrosoftUri => new Uri (MicrosoftUrl);
public static string MicrosoftHttpUrl => AssertNetworkConnection ("http://www.microsoft.com");
public static Uri MicrosoftHttpUri => new Uri (MicrosoftHttpUrl);
public static string XamarinUrl => AssertNetworkConnection ("https://dotnet.microsoft.com/apps/xamarin");
public static string XamarinHttpUrl => AssertNetworkConnection ("http://dotnet.microsoft.com/apps/xamarin");
public static Uri XamarinUri => new Uri (XamarinUrl);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,9 @@ public void TestCallbackBackground (bool stronglyTyped)
public void TestMultiImage (bool stronglyTyped, bool customCallback)
{
TestRuntime.AssertXcodeVersion (26, 0);
#if __MACOS__ || __MACCATALYST__
TestRuntime.AssertNotVirtualMachine ();
#endif

if (!VTCompressionSession.IsStereoMvHevcEncodeSupported ())
Assert.Ignore ("Stereo MV-HEVC encoding is not supported on the current system.");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ public class VTMotionEstimationSessionTest {
public void CreateTest ()
{
TestRuntime.AssertXcodeVersion (26, 0);
#if __MACOS__ || __MACCATALYST__
TestRuntime.AssertNotVirtualMachine ();
#endif
// VTMotionEstimationSessionCreate just returns in the simulator (a single 'ret' instruction),
// which means it returns with status=VTStatus.Ok, but no session actually created. So ignore
// this test in the simulator.
Expand All @@ -49,6 +52,9 @@ public void CreateTest ()
public void CreateStronglyTypedTest ()
{
TestRuntime.AssertXcodeVersion (26, 0);
#if __MACOS__ || __MACCATALYST__
TestRuntime.AssertNotVirtualMachine ();
#endif
// VTMotionEstimationSessionCreate just returns in the simulator (a single 'ret' instruction),
// which means it returns with status=VTStatus.Ok, but no session actually created. So ignore
// this test in the simulator.
Expand Down
7 changes: 7 additions & 0 deletions tests/xharness/AppRunner.cs
Original file line number Diff line number Diff line change
Expand Up @@ -225,6 +225,13 @@ public async Task<int> RunAsync ()
if (harness.InCI) {
// We use the 'BUILD_REVISION' variable to detect whether we're running CI or not.
args.Add (new SetEnvVariableArgument ("BUILD_REVISION", Environment.GetEnvironmentVariable ("BUILD_REVISION")));

// Forward VM_VENDOR (set by the pipeline when running on a VM-backed
// pool such as ACES) so TestRuntime.AssertNotVirtualMachine works
// inside the iOS/tvOS simulator process.
var vmVendor = Environment.GetEnvironmentVariable ("VM_VENDOR");
if (!string.IsNullOrEmpty (vmVendor))
args.Add (new SetEnvVariableArgument ("VM_VENDOR", vmVendor));
Comment thread
rolfbjarne marked this conversation as resolved.
}

if (!harness.GetIncludeSystemPermissionTests (TestPlatform.iOS, !isSimulator))
Expand Down
1 change: 1 addition & 0 deletions tools/devops/automation/build-pipeline.yml
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@ extends:
forceInsertion: ${{ parameters.forceInsertion }}
pushNugets: ${{ parameters.pushNugets }}
pushNugetsToMaestro: ${{ parameters.pushNugetsToMaestro }}
useACES: true # flip to false to opt CI out of ACES; see templates/variables/common.yml

- template: localization/v1.yml@yaml-templates
parameters:
Expand Down
1 change: 1 addition & 0 deletions tools/devops/automation/build-pull-request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -113,3 +113,4 @@ extends:
forceInsertion: ${{ parameters.forceInsertion }}
pushNugets: false
pushNugetsToMaestro: false
useACES: false # flip to true to opt PR into ACES; see templates/variables/common.yml
1 change: 1 addition & 0 deletions tools/devops/automation/run-ci-api-diff.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,4 @@ extends:
parameters:
isPR: false
pool: $(CIBuildPool)
useACES: true # flip to false to opt CI api-diff out of ACES; see templates/variables/common.yml
1 change: 1 addition & 0 deletions tools/devops/automation/run-post-ci-build-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,4 @@ extends:
template: templates/pipelines/run-tests-pipeline.yml
parameters:
isPR: false
useACES: true # flip to false to opt CI simulator tests out of ACES; see templates/variables/common.yml
1 change: 1 addition & 0 deletions tools/devops/automation/run-post-pr-build-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,3 +27,4 @@ extends:
parameters:
isPR: true
buildPackages: true
useACES: false # flip to true to opt PR simulator tests into ACES; see templates/variables/common.yml
1 change: 1 addition & 0 deletions tools/devops/automation/run-pr-api-diff.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,4 @@ extends:
parameters:
isPR: true
pool: $(PRBuildPool)
useACES: false # flip to true to opt PR api-diff into ACES; see templates/variables/common.yml
4 changes: 4 additions & 0 deletions tools/devops/automation/templates/api-diff-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ parameters:
- name: macOSName
type: string

- name: useACES
type: boolean
default: false


stages:
Expand Down Expand Up @@ -69,3 +72,4 @@ stages:
gitHubToken: $(Github.Token)
xqaCertPass: $(xqa--certificates--password)
pool: ${{ parameters.pool }}
useACES: ${{ parameters.useACES }}
24 changes: 17 additions & 7 deletions tools/devops/automation/templates/build/api-diff-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,10 @@ parameters:
- name: macOSName
type: string

- name: useACES
type: boolean
default: false

jobs:
# Detect changes
- job: api_diff
Expand All @@ -44,13 +48,19 @@ jobs:
# set the branch variable name, this is required by jenkins and we have a lot of scripts that depend on it
BRANCH_NAME: $[ replace(variables['Build.SourceBranch'], 'refs/heads/', '') ]
XHARNESS_LABELS: $[ stageDependencies.configure_build.configure.outputs['labels.xharness_labels'] ]
pool:
name: ${{ parameters.pool }}
demands:
- Agent.OS -equals Darwin
- Agent.OSVersion -gtVersion $(minimumMacOSVersion)
- macOS.Name -equals ${{ parameters.macOSName }}
- XcodeChannel -equals ${{ parameters.xcodeChannel }}
${{ if parameters.useACES }}:
pool:
name: $(CIBuildPoolACES)
demands:
- ImageOverride -equals $(CIBuildPoolACESImage)
${{ else }}:
pool:
name: ${{ parameters.pool }}
demands:
- Agent.OS -equals Darwin
- Agent.OSVersion -gtVersion $(minimumMacOSVersion)
- macOS.Name -equals ${{ parameters.macOSName }}
- XcodeChannel -equals ${{ parameters.xcodeChannel }}
workspace:
clean: all

Expand Down
27 changes: 19 additions & 8 deletions tools/devops/automation/templates/build/build-mac-tests-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,10 @@ parameters:
- name: macOSName
type: string

- name: useACES
type: boolean
default: false

jobs:

# This job builds the macOS tests.
Expand All @@ -49,14 +53,21 @@ jobs:
BRANCH_NAME: $[ replace(variables['Build.SourceBranch'], 'refs/heads/', '') ]
RUN_MAC_TESTS: $[ stageDependencies.configure_build.configure.outputs['decisions.RUN_MAC_TESTS'] ]
condition: ne(stageDependencies.configure_build.configure.outputs['decisions.RUN_MAC_TESTS'],'')
pool:
os: macOS
name: ${{ parameters.pool }}
demands:
- Agent.OS -equals Darwin
- Agent.OSVersion -gtVersion $(minimumMacOSVersion)
- macOS.Name -equals ${{ parameters.macOSName }}
- XcodeChannel -equals ${{ parameters.xcodeChannel }}
${{ if parameters.useACES }}:
pool:
os: macOS
name: $(CIBuildPoolACES)
demands:
- ImageOverride -equals $(CIBuildPoolACESImage)
${{ else }}:
pool:
os: macOS
name: ${{ parameters.pool }}
demands:
- Agent.OS -equals Darwin
- Agent.OSVersion -gtVersion $(minimumMacOSVersion)
- macOS.Name -equals ${{ parameters.macOSName }}
- XcodeChannel -equals ${{ parameters.xcodeChannel }}

steps:
- template: build-mac-tests.yml
Expand Down
27 changes: 19 additions & 8 deletions tools/devops/automation/templates/build/build-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ parameters:
- name: use1ES
type: boolean

- name: useACES
type: boolean
default: false

jobs:
# This job performs the build of the nuget pkgs and the framework pkgs. There are two interesting dependencies in this job:
- job: build
Expand Down Expand Up @@ -66,14 +70,21 @@ jobs:
BRANCH_NAME: $[ replace(variables['Build.SourceBranch'], 'refs/heads/', '') ]
XHARNESS_LABELS: $[ stageDependencies.configure_build.configure.outputs['labels.xharness_labels'] ]
RUN_MAC_TESTS: $[ stageDependencies.configure_build.configure.outputs['decisions.RUN_MAC_TESTS'] ]
pool:
os: macOS
name: ${{ parameters.pool }}
demands:
- Agent.OS -equals Darwin
- Agent.OSVersion -gtVersion $(minimumMacOSVersion)
- macOS.Name -equals ${{ parameters.macOSName }}
- XcodeChannel -equals ${{ parameters.xcodeChannel }}
${{ if parameters.useACES }}:
pool:
os: macOS
name: $(CIBuildPoolACES)
demands:
- ImageOverride -equals $(CIBuildPoolACESImage)
${{ else }}:
pool:
os: macOS
name: ${{ parameters.pool }}
demands:
- Agent.OS -equals Darwin
- Agent.OSVersion -gtVersion $(minimumMacOSVersion)
- macOS.Name -equals ${{ parameters.macOSName }}
- XcodeChannel -equals ${{ parameters.xcodeChannel }}

steps:
- template: build-pkgs.yml
Expand Down
5 changes: 5 additions & 0 deletions tools/devops/automation/templates/main-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,10 @@ parameters:
type: string
default: ''

- name: useACES
type: boolean
default: false

stages:

- stage: configure_build
Expand Down Expand Up @@ -103,6 +107,7 @@ stages:
xqaCertPass: $(xqa--certificates--password)
pool: ${{ parameters.pool }}
use1ES: true
useACES: ${{ parameters.useACES }}

# .NET Release Prep and VS Insertion Stages, only execute them when the build comes from an official branch and is not a schedule build from OneLoc
# setting the stage at this level makes the graph of the UI look better, else the lines overlap and is not clear.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ parameters:
type: boolean
default: false

- name: useACES
type: boolean
default: false

resources:
repositories:
- repository: self
Expand Down Expand Up @@ -49,3 +53,4 @@ stages:
isPR: ${{ parameters.isPR }}
provisionatorChannel: ${{ parameters.provisionatorChannel }}
pool: ${{ parameters.pool }}
useACES: ${{ parameters.useACES }}
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,11 @@ parameters:
type: boolean
default: false

- name: useACES
displayName: Use ACES shared pool for simulator tests
type: boolean
default: false

resources:
repositories:
- repository: self
Expand All @@ -62,3 +67,4 @@ stages:
runTests: ${{ parameters.runTests }}
runWindowsIntegration: ${{ parameters.runWindowsIntegration }}
buildPackages: ${{ parameters.buildPackages }}
useACES: ${{ parameters.useACES }}
6 changes: 6 additions & 0 deletions tools/devops/automation/templates/tests-stage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,10 @@ parameters:
type: boolean
default: false

- name: useACES
type: boolean
default: false

stages:

- template: ./build/linux-build-verification.yml
Expand Down Expand Up @@ -234,6 +238,7 @@ stages:
xqaCertPass: $(xqa--certificates--password)
condition: ${{ parameters.runTests }}
postPipeline: ${{ not(parameters.buildPackages) }}
useACES: ${{ parameters.useACES }}

- template: ./tests/publish-results.yml
parameters:
Expand Down Expand Up @@ -282,6 +287,7 @@ stages:
gitHubToken: $(Github.Token)
xqaCertPass: $(xqa--certificates--password)
pool: $(PRBuildPool)
useACES: ${{ parameters.useACES }}

- ${{ each config in parameters.macTestsConfigurations }}:
- template: ./mac/stage.yml
Expand Down
1 change: 1 addition & 0 deletions tools/devops/automation/templates/tests/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -208,6 +208,7 @@ steps:
provisioning_script: $(System.DefaultWorkingDirectory)/$(BUILD_REPOSITORY_TITLE)/tools/devops/build-provisioning.csx
displayName: 'Provisionator dependencies'
provisionatorChannel: $(PROVISIONATOR_CHANNEL)
retryCount: 3

- bash: |
set -x
Expand Down
2 changes: 1 addition & 1 deletion tools/devops/automation/templates/tests/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ parameters:

- name: retryCount
type: number
default: 3
default: 0

steps:
- bash: |
Expand Down
Loading
Loading