Fix TestDetect flakiness from concurrent Maven access to shared .m2#8837
Fix TestDetect flakiness from concurrent Maven access to shared .m2#8837Copilot wants to merge 2 commits into
Conversation
… subtests Co-authored-by: JeffreyCA <9157833+JeffreyCA@users.noreply.github.com>
|
/azp run azure-dev - cli |
|
Azure Pipelines successfully started running 1 pipeline(s). |
Azure Dev CLI Install InstructionsInstall scriptsMacOS/Linux
bash: pwsh: WindowsPowerShell install MSI install Standalone Binary
MSI
Documentationlearn.microsoft.com documentationtitle: Azure Developer CLI reference
|
TestDetect/FullandTestDetect/ExcludePatternsboth call realmvn help:effective-pomand ran as parallel subtests, racing to download artifacts into the shared~/.m2cache on a cold start — causing intermittent "Could not transfer artifact ... .tmp" failures on Windows CI.Changes
internal/appdetect/appdetect_test.go: Removet.Parallel()from the inner subtest loop inTestDetect, serializing the Maven-touching subtests relative to each other.The outer
t.Parallel()onTestDetectitself is preserved — the function still runs in parallel with other packages, only the subtests within it are now sequential.