test(bucket): Skip manifest validation if no manifest changes (#5270)

This commit is contained in:
Hsiao-nan Cheung
2022-11-30 13:32:35 +08:00
committed by GitHub
parent 360daa706a
commit af5ffcddab
2 changed files with 11 additions and 7 deletions
+8 -2
View File
@@ -1,10 +1,16 @@
## [Unreleased](https://github.com/ScoopInstaller/Scoop/compare/master...develop)
### Features
- **scoop-update:** Add support for parallel syncing buckets in PowerShell 7 and improve output ([#5122](https://github.com/ScoopInstaller/Scoop/pull/5122))
- **scoop-update:** Add support for parallel syncing buckets in PowerShell 7 and improve output ([#5122](https://github.com/ScoopInstaller/Scoop/issues/5122))
### Code Refactoring
- **git:** Use Invoke-Git() with direct path to git.exe to prevent spawning shim subprocesses ([#5122](https://github.com/ScoopInstaller/Scoop/pull/5122))
- **git:** Use Invoke-Git() with direct path to git.exe to prevent spawning shim subprocesses ([#5122](https://github.com/ScoopInstaller/Scoop/issues/5122))
### Tests
- **bucket:** Skip manifest validation if no manifest changes ([#5270](https://github.com/ScoopInstaller/Scoop/issues/5270))
## [v0.3.1](https://github.com/ScoopInstaller/Scoop/compare/v0.3.0...v0.3.1) - 2022-11-15
+3 -5
View File
@@ -16,11 +16,9 @@ Describe 'Manifest validates against the schema' {
}
if ($env:CI -eq $true) {
Set-BuildEnvironment -Force
$changedManifests = @(Get-GitChangedFile -Path $bucketDir -Include '*.json' -Commit $env:BHCommitHash)
}
$manifestFiles = (Get-ChildItem $bucketDir -Filter '*.json' -Recurse).FullName
if ($changedManifests) {
$manifestFiles = $manifestFiles | Where-Object { $_ -in $changedManifests }
$manifestFiles = @(Get-GitChangedFile -Path $bucketDir -Include '*.json' -Commit $env:BHCommitHash)
} else {
$manifestFiles = (Get-ChildItem $bucketDir -Filter '*.json' -Recurse).FullName
}
}
BeforeAll {