Skip to content

Commit

Permalink
Sync eng/common directory with azure-sdk-tools for PR 9635 (#32169)
Browse files Browse the repository at this point in the history
* ensure that packages that come back from AdditionalValidationPackages are NOT counted as 'includedForValidation: true' if they also exist in the original 'these packages changed' set

Co-authored-by: Ben Broderick Phillips <ben@benbp.net>

---------

Co-authored-by: Scott Beddall <scbedd@microsoft.com>
Co-authored-by: Scott Beddall <45376673+scbedd@users.noreply.github.com>
Co-authored-by: Ben Broderick Phillips <ben@benbp.net>
  • Loading branch information
4 people authored Jan 15, 2025
1 parent ca2053c commit 7e08d30
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions eng/common/scripts/Package-Properties.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -187,12 +187,17 @@ function Get-PrPkgProperties([string]$InputDiffJson) {
}
}

$existingPackageNames = @($packagesWithChanges | ForEach-Object { $_.Name })
foreach ($addition in $additionalValidationPackages) {
$key = $addition.Replace($RepoRoot, "").TrimStart('\/')

if ($lookup[$key]) {
$lookup[$key].IncludedForValidation = $true
$packagesWithChanges += $lookup[$key]
$pkg = $lookup[$key]

if ($pkg.Name -notin $existingPackageNames) {
$pkg.IncludedForValidation = $true
$packagesWithChanges += $pkg
}
}
}

Expand Down

0 comments on commit 7e08d30

Please sign in to comment.