Repository navigation
Restore local tools before Azure integration builds - #4952
Conversation
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
There was a problem hiding this comment.
🔵 Needs a closer look
Required trusted-base review-policy references were not supplied with an immutable source, leaving policy verification incomplete.
No open issues 🎉
What changed in this PR
Restores local tools before Azure integration builds, addressing the missing pwsh dependency introduced when #4890 made project-reference builds include SqlClient’s reference assembly. No public API or runtime behavior changes.
Changes:
- Invoke the shared tool-restore template after SDK installation for both reference modes.
- Add a Pester regression test checking unconditional restoration and bootstrap ordering.
| File | Description |
|---|---|
| eng/pipelines/scripts/tests/Build-Orchestration.Tests.ps1 | Tests that tool restoration occurs after SDK installation and before building. |
| eng/pipelines/jobs/test-azure-package-ci-job.yml | Adds shared local-tool restoration before Azure integration builds. |
Review effort: Balanced
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4952 +/- ##
==========================================
- Coverage 67.91% 66.64% -1.28%
==========================================
Files 311 305 -6
Lines 45286 68341 +23055
==========================================
+ Hits 30757 45543 +14786
- Misses 14529 22798 +8269
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Description
The Windows and Linux Azure integration jobs in #4890 failed because project-reference builds now reach the SqlClient reference assembly, whose documentation trimming requires the local
pwshtool.Invoke the existing shared tool-restore template after SDK installation and before building the Azure tests. Restore remains unconditional for both reference modes. Add a regression test that checks this ordering. No public API or runtime behavior changes.
Issues
Failures seen in #4890. Addresses the missing-tool failures in build 187521.
Testing
Added a Pester regression test for the Azure integration job bootstrap.
Passed: the following isolated run selected one test, which passed:
Passed:
dotnet msbuild src\Microsoft.Data.SqlClient\ref\Microsoft.Data.SqlClient.csproj -nologo -t:_CheckPwshToolRestored -p:TargetFramework=net10.0 -v:minimal.Passed:
git diff --check.The initial test invocation unexpectedly ran unrelated orchestration tests and was stopped after Windows argument-handling failures; the explicit Pester 5 invocation above correctly isolated the new test. Full Azure integration tests and an Azure Pipelines rerun were not performed locally.
Validations