From 2bb27d4b7ddec29b5a58291c1f2206865846d377 Mon Sep 17 00:00:00 2001 From: Azure SDK Bot <53356347+azure-sdk@users.noreply.github.com> Date: Wed, 9 Feb 2022 14:37:19 -0800 Subject: [PATCH] Add catch-all parameter to test resources script (#17025) Co-authored-by: Ben Broderick Phillips --- eng/common/TestResources/New-TestResources.ps1 | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/eng/common/TestResources/New-TestResources.ps1 b/eng/common/TestResources/New-TestResources.ps1 index d494ed1b9bd7..07ff0839b8ed 100644 --- a/eng/common/TestResources/New-TestResources.ps1 +++ b/eng/common/TestResources/New-TestResources.ps1 @@ -83,7 +83,14 @@ param ( [switch] $OutFile, [Parameter()] - [switch] $SuppressVsoCommands = ($null -eq $env:SYSTEM_TEAMPROJECTID) + [switch] $SuppressVsoCommands = ($null -eq $env:SYSTEM_TEAMPROJECTID), + + # Captures any arguments not declared here (no parameter errors) + # This enables backwards compatibility with old script versions in + # hotfix branches if and when the dynamic subscription configuration + # secrets get updated to add new parameters. + [Parameter(ValueFromRemainingArguments = $true)] + $NewTestResourcesRemainingArguments ) . $PSScriptRoot/SubConfig-Helpers.ps1