From 37e7adcc6623c232857cfb65ad6ea5f989ea7fc6 Mon Sep 17 00:00:00 2001 From: Jonathan Reynes <19974635+jontreynes@users.noreply.github.com> Date: Thu, 27 May 2021 23:53:37 -0400 Subject: [PATCH] Update Test Deployments to allow the user to specify a deployment name (#15082) * Update TestAzureSubscriptionDeploymentCmdlet.cs * For TestAzureSubscriptionDeployment - If deployment name is null, then generate the name, otherwise, pass the deployment name * Allow to specify deployment name for validate on management group, subscription, and tenant deployments * changelog Allow naming the deployment when testing deployments [#11497] * change help message * Update-MarkdownHelpModule Co-authored-by: Jonathan Reynes --- ...estAzureManagementGroupDeploymentCmdlet.cs | 7 ++ .../TestAzureSubscriptionDeploymentCmdlet.cs | 7 ++ .../TestAzureTenantDeploymentCmdlet.cs | 7 ++ .../SdkClient/ResourceManagerSdkClient.cs | 4 +- src/Resources/Resources/ChangeLog.md | 1 + .../help/Test-AzManagementGroupDeployment.md | 118 +++++++++++------- .../Resources/help/Test-AzTenantDeployment.md | 102 +++++++++------ 7 files changed, 157 insertions(+), 89 deletions(-) diff --git a/src/Resources/ResourceManager/Implementation/Deployments/TestAzureManagementGroupDeploymentCmdlet.cs b/src/Resources/ResourceManager/Implementation/Deployments/TestAzureManagementGroupDeploymentCmdlet.cs index 8e0f783e0ce9..54aec7b27d48 100644 --- a/src/Resources/ResourceManager/Implementation/Deployments/TestAzureManagementGroupDeploymentCmdlet.cs +++ b/src/Resources/ResourceManager/Implementation/Deployments/TestAzureManagementGroupDeploymentCmdlet.cs @@ -28,6 +28,12 @@ namespace Microsoft.Azure.Commands.ResourceManager.Cmdlets.Implementation [Cmdlet(VerbsDiagnostic.Test, AzureRMConstants.AzureRMPrefix + "ManagementGroupDeployment", DefaultParameterSetName = ParameterlessTemplateFileParameterSetName), OutputType(typeof(PSResourceManagerError))] public class TestAzureManagementGroupDeploymentCmdlet : TestDeploymentCmdletBase { + [Alias("DeploymentName")] + [Parameter(Mandatory = false, + HelpMessage = "The name of the deployment it's going to test. If not specified, defaults to the template file name when a template file is provided")] + [ValidateNotNullOrEmpty] + public string Name { get; set; } + [Parameter(Mandatory = true, HelpMessage = "The management group id.")] [ValidateNotNullOrEmpty] public string ManagementGroupId { get; set; } @@ -44,6 +50,7 @@ protected override void OnProcessRecord() ScopeType = DeploymentScopeType.ManagementGroup, ManagementGroupId = this.ManagementGroupId, Location = this.Location, + DeploymentName = this.Name, QueryString = QueryString, TemplateFile = this.TemplateUri ?? this.TryResolvePath(this.TemplateFile), TemplateObject = this.TemplateObject, diff --git a/src/Resources/ResourceManager/Implementation/Deployments/TestAzureSubscriptionDeploymentCmdlet.cs b/src/Resources/ResourceManager/Implementation/Deployments/TestAzureSubscriptionDeploymentCmdlet.cs index a2853dccdf84..f390e4401aea 100644 --- a/src/Resources/ResourceManager/Implementation/Deployments/TestAzureSubscriptionDeploymentCmdlet.cs +++ b/src/Resources/ResourceManager/Implementation/Deployments/TestAzureSubscriptionDeploymentCmdlet.cs @@ -29,6 +29,12 @@ namespace Microsoft.Azure.Commands.ResourceManager.Cmdlets.Implementation [Alias("Test-AzSubscriptionDeployment")] public class TestAzureSubscriptionDeploymentCmdlet : TestDeploymentCmdletBase { + [Alias("DeploymentName")] + [Parameter(Mandatory = false, + HelpMessage = "The name of the deployment it's going to test. If not specified, defaults to the template file name when a template file is provided")] + [ValidateNotNullOrEmpty] + public string Name { get; set; } + [Parameter(Mandatory = true, HelpMessage = "The location to store deployment data.")] [LocationCompleter("Microsoft.Resources/resourceGroups")] [ValidateNotNullOrEmpty] @@ -40,6 +46,7 @@ protected override void OnProcessRecord() { ScopeType = DeploymentScopeType.Subscription, Location = Location, + DeploymentName = this.Name, TemplateFile = TemplateUri ?? this.TryResolvePath(TemplateFile), TemplateObject = TemplateObject, QueryString = QueryString, diff --git a/src/Resources/ResourceManager/Implementation/Deployments/TestAzureTenantDeploymentCmdlet.cs b/src/Resources/ResourceManager/Implementation/Deployments/TestAzureTenantDeploymentCmdlet.cs index 74225f662c7b..c5d18c0e089e 100644 --- a/src/Resources/ResourceManager/Implementation/Deployments/TestAzureTenantDeploymentCmdlet.cs +++ b/src/Resources/ResourceManager/Implementation/Deployments/TestAzureTenantDeploymentCmdlet.cs @@ -29,6 +29,12 @@ namespace Microsoft.Azure.Commands.ResourceManager.Cmdlets.Implementation DefaultParameterSetName = ParameterlessTemplateFileParameterSetName), OutputType(typeof(PSResourceManagerError))] public class TestAzureTenantDeploymentCmdlet : TestDeploymentCmdletBase { + [Alias("DeploymentName")] + [Parameter(Mandatory = false, + HelpMessage = "The name of the deployment it's going to test. If not specified, defaults to the template file name when a template file is provided")] + [ValidateNotNullOrEmpty] + public string Name { get; set; } + [Parameter(Mandatory = true, HelpMessage = "The location to store deployment data.")] [LocationCompleter("Microsoft.Resources/resourceGroups")] [ValidateNotNullOrEmpty] @@ -40,6 +46,7 @@ protected override void OnProcessRecord() { ScopeType = DeploymentScopeType.Tenant, Location = this.Location, + DeploymentName = this.Name, TemplateFile = this.TemplateUri ?? this.TryResolvePath(this.TemplateFile), TemplateObject = this.TemplateObject, QueryString = QueryString, diff --git a/src/Resources/ResourceManager/SdkClient/ResourceManagerSdkClient.cs b/src/Resources/ResourceManager/SdkClient/ResourceManagerSdkClient.cs index c1ce8cace0ec..20a09c4094b7 100644 --- a/src/Resources/ResourceManager/SdkClient/ResourceManagerSdkClient.cs +++ b/src/Resources/ResourceManager/SdkClient/ResourceManagerSdkClient.cs @@ -1671,7 +1671,9 @@ private void CancelDeploymentAtResourceGroup(List deployments, str /// The validation errors if there's any, or empty list otherwise. public virtual List ValidateDeployment(PSDeploymentCmdletParameters parameters) { - parameters.DeploymentName = GenerateDeploymentName(parameters); + if (parameters.DeploymentName == null){ + parameters.DeploymentName = GenerateDeploymentName(parameters); + } Deployment deployment = CreateBasicDeployment(parameters, parameters.DeploymentMode, null); var validationInfo = this.GetTemplateValidationResult(parameters, deployment); diff --git a/src/Resources/Resources/ChangeLog.md b/src/Resources/Resources/ChangeLog.md index a202b1353f37..9e96c99e3162 100644 --- a/src/Resources/Resources/ChangeLog.md +++ b/src/Resources/Resources/ChangeLog.md @@ -19,6 +19,7 @@ --> ## Upcoming Release +* Allow naming the deployment when testing deployments [#11497] ## Version 4.1.0 * Changed `-IdentifierUris` in `New-AzADApplication` to optional parameter diff --git a/src/Resources/Resources/help/Test-AzManagementGroupDeployment.md b/src/Resources/Resources/help/Test-AzManagementGroupDeployment.md index e8f05c32a49b..722329e36b6c 100644 --- a/src/Resources/Resources/help/Test-AzManagementGroupDeployment.md +++ b/src/Resources/Resources/help/Test-AzManagementGroupDeployment.md @@ -14,107 +14,114 @@ Validates a deployment at a management group. ### ByTemplateFileWithNoParameters (Default) ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateObjectAndParameterObject ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateParameterObject -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] - [-DefaultProfile ] [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterObject -TemplateObject + [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateFileAndParameterObject ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateParameterObject -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] - [-DefaultProfile ] [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterObject -TemplateFile + [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateUriAndParameterObject ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateParameterObject -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] - [-DefaultProfile ] [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterObject -TemplateUri + [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] [] +``` + +### ByTemplateSpecResourceIdAndParamsObject +``` +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterObject -TemplateSpecId + [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateObjectAndParameterFile ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateParameterFile -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] - [-DefaultProfile ] [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterFile -TemplateObject + [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateFileAndParameterFile ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateParameterFile -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] - [-DefaultProfile ] [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterFile -TemplateFile [-SkipTemplateParameterPrompt] + [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateUriAndParameterFile ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateParameterFile -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] - [-DefaultProfile ] [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterFile -TemplateUri [-SkipTemplateParameterPrompt] + [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateSpecResourceIdAndParams ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateParameterFile -TemplateSpecId [-SkipTemplateParameterPrompt] [-Pre] - [-DefaultProfile ] [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterFile -TemplateSpecId + [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateObjectAndParameterUri ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateParameterUri -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] - [-DefaultProfile ] [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterUri -TemplateObject + [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateFileAndParameterUri ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateParameterUri -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] - [-DefaultProfile ] [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterUri -TemplateFile [-SkipTemplateParameterPrompt] + [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateUriAndParameterUri ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateParameterUri -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] - [-DefaultProfile ] [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterUri -TemplateUri [-SkipTemplateParameterPrompt] + [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateSpecResourceIdAndParamsUri ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateParameterUri -TemplateSpecId [-SkipTemplateParameterPrompt] [-Pre] - [-DefaultProfile ] [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateParameterUri -TemplateSpecId [-SkipTemplateParameterPrompt] + [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateObjectWithNoParameters ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateUriWithNoParameters ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateSpecResourceId ``` -Test-AzManagementGroupDeployment -ManagementGroupId -Location [-QueryString ] - -TemplateSpecId [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzManagementGroupDeployment [-Name ] -ManagementGroupId -Location + [-QueryString ] -TemplateSpecId [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ## DESCRIPTION @@ -185,6 +192,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -Name +The name of the deployment it's going to test. If not specified, defaults to the template file name when a template file is provided + +```yaml +Type: System.String +Parameter Sets: (All) +Aliases: DeploymentName + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -Pre When set, indicates that the cmdlet should use pre-release API versions when automatically determining which version to use. @@ -282,7 +304,7 @@ A hash table which represents the parameters. ```yaml Type: System.Collections.Hashtable -Parameter Sets: ByTemplateObjectAndParameterObject, ByTemplateFileAndParameterObject, ByTemplateUriAndParameterObject +Parameter Sets: ByTemplateObjectAndParameterObject, ByTemplateFileAndParameterObject, ByTemplateUriAndParameterObject, ByTemplateSpecResourceIdAndParamsObject Aliases: Required: True @@ -312,7 +334,7 @@ Resource ID of the templateSpec to be deployed. ```yaml Type: System.String -Parameter Sets: ByTemplateSpecResourceIdAndParams, ByTemplateSpecResourceIdAndParamsUri, ByTemplateSpecResourceId +Parameter Sets: ByTemplateSpecResourceIdAndParamsObject, ByTemplateSpecResourceIdAndParams, ByTemplateSpecResourceIdAndParamsUri, ByTemplateSpecResourceId Aliases: Required: True @@ -352,4 +374,4 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## NOTES -## RELATED LINKS +## RELATED LINKS \ No newline at end of file diff --git a/src/Resources/Resources/help/Test-AzTenantDeployment.md b/src/Resources/Resources/help/Test-AzTenantDeployment.md index e7f094de45f8..f2732cd10540 100644 --- a/src/Resources/Resources/help/Test-AzTenantDeployment.md +++ b/src/Resources/Resources/help/Test-AzTenantDeployment.md @@ -14,102 +14,109 @@ Validates a deployment at tenant scope. ### ByTemplateFileWithNoParameters (Default) ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateFile +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateObjectAndParameterObject ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateParameterObject - -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterObject -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateFileAndParameterObject ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateParameterObject - -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterObject -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateUriAndParameterObject ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateParameterObject - -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterObject -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] +``` + +### ByTemplateSpecResourceIdAndParamsObject +``` +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterObject -TemplateSpecId [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateObjectAndParameterFile ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateParameterFile - -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterFile -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateFileAndParameterFile ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateParameterFile - -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterFile -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateUriAndParameterFile ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateParameterFile - -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterFile -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateSpecResourceIdAndParams ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateParameterFile - -TemplateSpecId [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterFile -TemplateSpecId [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateObjectAndParameterUri ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateParameterUri - -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterUri -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateFileAndParameterUri ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateParameterUri - -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterUri -TemplateFile [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateUriAndParameterUri ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateParameterUri - -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterUri -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateSpecResourceIdAndParamsUri ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateParameterUri - -TemplateSpecId [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] - [] +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] + -TemplateParameterUri -TemplateSpecId [-SkipTemplateParameterPrompt] [-Pre] + [-DefaultProfile ] [] ``` ### ByTemplateObjectWithNoParameters ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateObject +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] -TemplateObject [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateUriWithNoParameters ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateUri +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] -TemplateUri [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] [] ``` ### ByTemplateSpecResourceId ``` -Test-AzTenantDeployment -Location [-QueryString ] -TemplateSpecId +Test-AzTenantDeployment [-Name ] -Location [-QueryString ] -TemplateSpecId [-SkipTemplateParameterPrompt] [-Pre] [-DefaultProfile ] [] ``` @@ -166,6 +173,21 @@ Accept pipeline input: False Accept wildcard characters: False ``` +### -Name +The name of the deployment it's going to test. If not specified, defaults to the template file name when a template file is provided + +```yaml +Type: System.String +Parameter Sets: (All) +Aliases: DeploymentName + +Required: False +Position: Named +Default value: None +Accept pipeline input: False +Accept wildcard characters: False +``` + ### -Pre When set, indicates that the cmdlet should use pre-release API versions when automatically determining which version to use. @@ -263,7 +285,7 @@ A hash table which represents the parameters. ```yaml Type: System.Collections.Hashtable -Parameter Sets: ByTemplateObjectAndParameterObject, ByTemplateFileAndParameterObject, ByTemplateUriAndParameterObject +Parameter Sets: ByTemplateObjectAndParameterObject, ByTemplateFileAndParameterObject, ByTemplateUriAndParameterObject, ByTemplateSpecResourceIdAndParamsObject Aliases: Required: True @@ -293,7 +315,7 @@ Resource ID of the templateSpec to be deployed. ```yaml Type: System.String -Parameter Sets: ByTemplateSpecResourceIdAndParams, ByTemplateSpecResourceIdAndParamsUri, ByTemplateSpecResourceId +Parameter Sets: ByTemplateSpecResourceIdAndParamsObject, ByTemplateSpecResourceIdAndParams, ByTemplateSpecResourceIdAndParamsUri, ByTemplateSpecResourceId Aliases: Required: True @@ -333,4 +355,4 @@ This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable ## NOTES -## RELATED LINKS +## RELATED LINKS \ No newline at end of file