Skip to content

Commit 81e59ad

Browse files
authored
Run release tests with -NonInteractive so a missing mandatory parameter fails instead of hanging (#2964)
Hardening backport from main. The release runs the tests as `pwsh -noprofile -c "test.ps1"` nested inside the AzureCLI task, whose host allows prompting. A test that invokes a command with a missing mandatory parameter would then prompt for the value and block forever on the agent, instead of throwing. Add -NonInteractive so the release test run stays non-interactive, like the PR pipeline.
1 parent 2f9fdbb commit 81e59ad

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

publish/release.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ if ($SkipTests) {
4949
Write-Host "Skipping tests because -SkipTests was specified."
5050
}
5151
else {
52-
pwsh -noprofile -c "$PSSCriptRoot/../test.ps1 -nobuild"
52+
pwsh -noprofile -NonInteractive -c "$PSSCriptRoot/../test.ps1 -nobuild"
5353
if ($LASTEXITCODE -ne 0) {
5454
throw "test failed!"
5555
}

0 commit comments

Comments
 (0)