Repository navigation
Tags
Tags
[ci] Pin test slicer to repo-local runtime (#12706) ## Why Hosted macOS builds [1574631](https://dev.azure.com/dnceng-public/public/_build/results?buildId=1574631) and [1574989](https://dev.azure.com/dnceng-public/public/_build/results?buildId=1574989) installed `dotnet-test-slicer` successfully, then failed before running tests because its native apphost could not locate .NET. The tool was invoked by absolute path, so adding its directory to `PATH` did not help runtime discovery; both `DOTNET_ROOT_X64` and `DOTNET_ROOT` were unset. The pinned slicer package targets `net8.0` with `rollForward: LatestMajor`, while test setup already installs the repository-pinned compatible SDK under `bin/$(XA.Build.Configuration)/dotnet`. Tracked by #12704. ## What changed - Set `DOTNET_ROOT` to the repo-local SDK for every initial and retry slicer invocation. - Forward `xaSourcePath` through the emulator-stage template so custom checkout paths resolve the same SDK installed during setup. ## Validation - Parsed both changed YAML templates and checked parameter substitution for a custom source root. - Confirmed all three slicer invocations receive the expanded repo-local `DOTNET_ROOT`. - Launched `dotnet-test-slicer` 0.1.0-alpha7 successfully against a .NET 11-only runtime root, exercising its configured major-version roll-forward. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
PreviousNext