diff --git a/azure-pipelines/end-to-end-tests-dir/upgrade.ps1 b/azure-pipelines/end-to-end-tests-dir/upgrade.ps1 index e01bfb276d..4d5a95123b 100644 --- a/azure-pipelines/end-to-end-tests-dir/upgrade.ps1 +++ b/azure-pipelines/end-to-end-tests-dir/upgrade.ps1 @@ -73,3 +73,12 @@ if (-Not ($output -match 'upgrade-test-port:[^:]+: SUCCEEDED:')) { throw "Upgrade didn't install" } + +# Also test providing a nonexistent name + +$output = Run-VcpkgAndCaptureStdErr upgrade nonexistent "--x-builtin-ports-root=$portsRoot" @commonArgs +Throw-IfNotFailed +if ($output -match 'internal error:') +{ + throw "Upgrade with a nonexistent name crashed" +}