Repository navigation
Avoid staging macOS app test fixtures in system temp - #17409
Merged
Merged
Conversation
Keep macOS package and signing test workspaces under the build artifacts directory, including nested package extraction scratch paths, to avoid triggering endpoint protection heuristics. Co-authored-by: Copilot <[email protected]> Copilot-Session: 9f27e529-3921-42bd-9a9b-4932badf6b59
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adjusts macOS packaging/signing test and extraction workflows to avoid staging executable-containing fixtures under the system temp directory, instead keeping workspaces under the build output/artifacts area to reduce endpoint protection (Defender) heuristic triggers.
Changes:
- Move
SignToolTestsfixture staging fromPath.GetTempPath()toAppContext.BaseDirectory/test-artifacts/.... - Keep nested
.pkgrepack scratch paths and payload extraction scratch directories within the caller-provided workspace (dstPath) instead of system temp. - Update
UnpackPackTeststo allocate all temp paths under a per-testtestRootworkspace (and add cleanup viaIDisposable).
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/Microsoft.DotNet.SignTool.Tests/SignToolTests.cs | Moves signing test fixture staging under the test output directory instead of system temp. |
| src/Microsoft.DotNet.MacOsPkg/Core/Package.cs | Keeps nested package repack and payload extraction scratch paths within the unpack workspace. |
| src/Microsoft.DotNet.MacOsPkg.Tests/UnpackPackTests.cs | Makes MacOsPkg tests use a dedicated workspace under build output and adds cleanup. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Co-authored-by: Copilot Autofix powered by AI <[email protected]>
ViktorHofer
approved these changes
Aug 27, 2026
Member
Author
|
/backport to release/11.0 |
Contributor
|
Started backporting to |
Member
Author
|
/backport to release/10.0 |
Contributor
|
Started backporting to |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Keep macOS package and signing test workspaces under the build artifacts directory, including nested package extraction scratch paths, to avoid triggering Defender endpoint protection heuristics.
Co-authored-by: Copilot [email protected]
To double check: