Skip to content

Commit 91d0038

Browse files
committed
Merge branch 'clu'
2 parents 0ca0508 + e46880d commit 91d0038

File tree

230 files changed

+26728
-312
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

230 files changed

+26728
-312
lines changed

build.proj

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,11 @@
182182
Dnx uses dynamic compilation, 'clean' is unnecessary -->
183183
<Target
184184
Name="Full"
185-
DependsOnTargets="Build;Test" />
185+
DependsOnTargets="Build;Test" >
186+
<Exec Command="$(LibraryToolsFolder)\CLU\BuildAndInstallClu.bat" />
187+
<!--do a simple verification-->
188+
<Exec Command="$(LibraryRoot)drop\clurun\win7-x64\azure.bat help" />
189+
</Target>
186190

187191
<Target Name="BuildMsBuildTask" DependsOnTargets="RestoreNugetPackages">
188192
<MSBuild Projects="$(LibraryToolsFolder)\BuildPackagesTask\Microsoft.Azure.Build.Tasks.csproj"
@@ -313,7 +317,7 @@
313317
<Message Importance="high" Text="Running check in tests..." />
314318
<ItemGroup>
315319
<!--Exclude 1 test projects still in progress with build failures-->
316-
<_CLUTestProjects Include="$(CLURootDir)\*.Test\project.json">
320+
<_CLUTestProjects Include="$(CLURootDir)\*.Test\project.json" Exclude="$(CLURootDir)\Microsoft.CLU.Test\project.json">
317321
</_CLUTestProjects>
318322
</ItemGroup>
319323
<Exec Command="dnu build" WorkingDirectory="%(_CLUTestProjects.RootDir)%(_CLUTestProjects.Directory)" />

clu-getstart.md

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,3 +78,36 @@ To test on osx/linux boxes, do #1, open `<repo-root>\drop\clurun`, you should se
7878

7979
```set CmdletSessionId=1010 ```
8080

81+
### Testing Cmdlets
82+
83+
#### Environment setup (Windows)
84+
- Install latest version of [Git for Windows](https://git-scm.com/download/win) that has `bash 4.x` available.
85+
- Install `jq` using chocolatey `choco install jq` (chocolatey can be installed from [here](https://chocolatey.org/)).
86+
87+
#### Test Infrastructure
88+
Testing will consist of scenario tests and unit tests. Scenario tests should be written in a form of an example and be available in `.ps1` and `.sh` formats.
89+
90+
#### Scenario Tests
91+
- Scenario tests should be saved under `./examples` directory and grouped by the package or service area. Each scenario tests should consist of both `.ps1` and `.sh` files and should cover "P0" scenarios.
92+
93+
##### Bash Tests
94+
- Bash tests should be runnable from bash shell in windows/linux/mac environments.
95+
- To manually run the tests; please set the following envt. variables for authentication and run `./examples/lib/testrunner.sh`
96+
```bash
97+
export azureuser=<[email protected]>
98+
export azurepassword=<your_password>
99+
export PATH=$PATH:/<path-to-drop>/clurun/win7-x64/
100+
. /examples/lib/testrunner.sh
101+
```
102+
- All the parameters to the cmdlets should be passed in as envt. variables
103+
- The current test runners will provide a unique resource group name via `$groupName` but may not remove it at the end if the test fails.
104+
- The location for ARM will be provided via variable `$location`.
105+
- "jq" package and BASH assert (e.g. `[ "foo" == "bar" ]`) should be used to validate the responses.
106+
107+
##### PowerShell Tests
108+
TODO: Add section on PowerShell testing
109+
110+
#### Unit Tests
111+
TODO: Add section on unit testing
112+
113+

examples/lib/helper.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
#!/bin/bash
2+
13
randomName() {
24
echo "$1$RANDOM"
35
}

examples/lib/setup.sh

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,17 @@
11
#!/bin/bash
2-
32
# Login
4-
echo "Executing Login..."
5-
export CmdletSessionId=1010
6-
azure account add --username $azureuser --password $azurepassword
3+
login() {
4+
echo "Executing Login..."
5+
export CmdletSessionId=1010
6+
azure account add --username $azureuser --password $azurepassword
7+
}
8+
9+
cleanup() {
10+
set +e
11+
printf "\nCleanup: removing resource group: %s\n" $groupName
12+
azure group remove --name "$groupName" --force
13+
set -e
14+
}
15+
16+
export -f login
17+
export -f cleanup

examples/lib/testrunner.sh

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,18 @@
11
#!/bin/bash
2-
. setup.sh
3-
. helper.sh
4-
export resourceGroupName=`randomName testrg`
5-
export resourceGroupLocation="westus"
2+
export BASEDIR=$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)
3+
. $BASEDIR/assert.sh
4+
. $BASEDIR/helper.sh
5+
. $BASEDIR/setup.sh
6+
export groupName=`randomName testrg`
7+
export location="westus"
68

7-
for d in $( ls .. --ignore=lib ); do
8-
for f in $( ls ../$d/*.sh ); do
9+
login
10+
11+
for d in $( ls $BASEDIR/.. --ignore=lib ); do
12+
for f in $( ls $BASEDIR/../$d/*.sh ); do
913
echo "running: $f"
1014
. $f
15+
cleanup
16+
echo "success: $f"
1117
done
1218
done
Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,21 @@
11
#!/bin/bash
2-
2+
set -e
33
printf "\n=== Managing Resource Groups in Azure ===\n"
44

5-
printf "\n1. Creating a new resource group: %s and location: %s.\n" "$resourceGroupName" "$resourceGroupLocation"
6-
azure resource group new --name "$resourceGroupName" --location "$resourceGroupLocation"
5+
printf "\n1. Creating a new resource group: %s and location: %s.\n" "$groupName" "$location"
6+
azure group create --name "$groupName" --location "$location"
7+
8+
printf "\n2. Updating the group %s with tags.\n" "$groupName"
9+
azure group set --name "$groupName" --tags "[{\"Value\":\"testval\",\"Name\":\"testtag\"}]"
710

8-
printf "\n2. Updating the group %s with tags.\n" "$resourceGroupName"
9-
azure resource group set --name "$resourceGroupName" --tags "[{\"Value\":\"testval\",\"Name\":\"testtag\"}]"
11+
printf "\n3. Get information about resource group : %s.\n" "$groupName"
12+
resourceGroupInfo=`azure group get --name $groupName`
1013

11-
printf "\n3. Get information about resource group : %s.\n" "$resourceGroupName"
12-
resourceGroupInfo=`azure resource group get --name $resourceGroupName`
13-
printf "\nThe resource group info is: \n %s\n" "$resourceGroupInfo"
14+
printf "\nValidating resource group name is: %s\n" "$groupName"
15+
[ $(echo $resourceGroupInfo | jq '.ResourceGroupName' --raw-output) == "$groupName" ]
1416

1517
printf "\n4. Listing all resource groups in the subscription.\n"
16-
azure resource group get
18+
azure group get
1719

18-
printf "\n5. Removing resource group: %s.\n" "$resourceGroupName"
19-
azure resource group remove --name "$resourceGroupName" --force
20+
printf "\n5. Removing resource group: %s.\n" "$groupName"
21+
azure group remove --name "$groupName" --force

src/CLU/CLUCoreCLR.sln

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,22 @@ Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "Microsoft.CLU", "Microsoft.
3939
EndProject
4040
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "Microsoft.CLU.Test", "Microsoft.CLU.Test\Microsoft.CLU.Test.xproj", "{91422B55-28A5-48DE-BCA0-30C3E30FFB1C}"
4141
EndProject
42+
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "Microsoft.Azure.Commands.Compute", "Microsoft.Azure.Commands.Compute\Microsoft.Azure.Commands.Compute.xproj", "{04F9968A-5662-4508-BEE2-31F56848FCBA}"
43+
ProjectSection(ProjectDependencies) = postProject
44+
{99B1290D-A073-4907-8018-51C714431778} = {99B1290D-A073-4907-8018-51C714431778}
45+
{3910613E-4ED2-49E2-8CCF-966D586665AC} = {3910613E-4ED2-49E2-8CCF-966D586665AC}
46+
{81A48E48-89A7-4B93-8207-4F8FA6DC251B} = {81A48E48-89A7-4B93-8207-4F8FA6DC251B}
47+
{45B05B68-516F-4D74-897F-56D12894946C} = {45B05B68-516F-4D74-897F-56D12894946C}
48+
EndProjectSection
49+
EndProject
50+
Project("{8BB2217D-0F2D-49D1-97BC-3654ED321F3B}") = "Microsoft.Azure.Commands.Compute.Test", "Microsoft.Azure.Commands.Compute.Test\Microsoft.Azure.Commands.Compute.Test.xproj", "{13C34370-51A4-4726-81B8-BE0996FC9CFF}"
51+
ProjectSection(ProjectDependencies) = postProject
52+
{3910613E-4ED2-49E2-8CCF-966D586665AC} = {3910613E-4ED2-49E2-8CCF-966D586665AC}
53+
{81A48E48-89A7-4B93-8207-4F8FA6DC251B} = {81A48E48-89A7-4B93-8207-4F8FA6DC251B}
54+
{A9CC2879-D45D-4DCB-A405-6EEDB749B15F} = {A9CC2879-D45D-4DCB-A405-6EEDB749B15F}
55+
{04F9968A-5662-4508-BEE2-31F56848FCBA} = {04F9968A-5662-4508-BEE2-31F56848FCBA}
56+
EndProjectSection
57+
EndProject
4258
Global
4359
GlobalSection(SolutionConfigurationPlatforms) = preSolution
4460
Debug|Any CPU = Debug|Any CPU
@@ -117,6 +133,14 @@ Global
117133
{91422B55-28A5-48DE-BCA0-30C3E30FFB1C}.Debug|Any CPU.Build.0 = Debug|Any CPU
118134
{91422B55-28A5-48DE-BCA0-30C3E30FFB1C}.Release|Any CPU.ActiveCfg = Release|Any CPU
119135
{91422B55-28A5-48DE-BCA0-30C3E30FFB1C}.Release|Any CPU.Build.0 = Release|Any CPU
136+
{04F9968A-5662-4508-BEE2-31F56848FCBA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
137+
{04F9968A-5662-4508-BEE2-31F56848FCBA}.Debug|Any CPU.Build.0 = Debug|Any CPU
138+
{04F9968A-5662-4508-BEE2-31F56848FCBA}.Release|Any CPU.ActiveCfg = Release|Any CPU
139+
{04F9968A-5662-4508-BEE2-31F56848FCBA}.Release|Any CPU.Build.0 = Release|Any CPU
140+
{13C34370-51A4-4726-81B8-BE0996FC9CFF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
141+
{13C34370-51A4-4726-81B8-BE0996FC9CFF}.Debug|Any CPU.Build.0 = Debug|Any CPU
142+
{13C34370-51A4-4726-81B8-BE0996FC9CFF}.Release|Any CPU.ActiveCfg = Release|Any CPU
143+
{13C34370-51A4-4726-81B8-BE0996FC9CFF}.Release|Any CPU.Build.0 = Release|Any CPU
120144
EndGlobalSection
121145
GlobalSection(SolutionProperties) = preSolution
122146
HideSolutionNode = FALSE

src/CLU/Commands.Common.Authentication/Authentication/UserTokenProvider.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,6 @@ private AuthenticationContext CreateContext(AdalConfiguration config)
107107
private AuthenticationResult AcquireToken(AdalConfiguration config, AuthenticationBehavior behavior, string userId,
108108
string password)
109109
{
110-
AuthenticationResult result = null;
111110
var context = CreateContext(config);
112111

113112
ServiceClientTracing.Information(

src/CLU/Commands.Common.Authentication/project.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@
1717
"dependencies": {
1818
"System.Linq": "4.0.1-beta-23516",
1919
"Microsoft.CLU": "1.0.0",
20-
"Microsoft.IdentityModel.Clients.ActiveDirectory": "3.6.210231457-alpha",
21-
"Microsoft.Rest.ClientRuntime": "1.5.0",
22-
"Microsoft.Rest.ClientRuntime.Azure.Authentication": "1.0.0-preview",
20+
"Microsoft.IdentityModel.Clients.ActiveDirectory": "3.6.212041202-alpha",
21+
"Microsoft.Rest.ClientRuntime": "1.8.0",
22+
"Microsoft.Rest.ClientRuntime.Azure.Authentication": "1.2.1-preview",
2323
"Newtonsoft.Json": "7.0.1",
2424
"System.Collections": "4.0.11-beta-23516",
2525
"System.Collections.Concurrent": "4.0.11-beta-23516",

src/CLU/Commands.Common.Storage/project.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,8 @@
1919
"Microsoft.CLU": "1.0.0",
2020
"Commands.Common": "",
2121
"Commands.Common.Authentication": "",
22-
"Microsoft.IdentityModel.Clients.ActiveDirectory": "3.6.210231457-alpha",
23-
"Microsoft.Rest.ClientRuntime": "1.5.0",
22+
"Microsoft.IdentityModel.Clients.ActiveDirectory": "3.6.212041202-alpha",
23+
"Microsoft.Rest.ClientRuntime": "1.8.0",
2424
"Newtonsoft.Json": "7.0.1",
2525
"System.Collections": "4.0.11-beta-23516",
2626
"System.Collections.Concurrent": "4.0.11-beta-23516",

src/CLU/Commands.Common/project.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@
1818
"System.Linq": "4.0.1-beta-23516",
1919
"Microsoft.CLU": "1.0.0",
2020
"Commands.Common.Authentication": "",
21-
"Microsoft.IdentityModel.Clients.ActiveDirectory": "3.6.210231457-alpha",
22-
"Microsoft.Rest.ClientRuntime": "1.5.0",
21+
"Microsoft.IdentityModel.Clients.ActiveDirectory": "3.6.212041202-alpha",
22+
"Microsoft.Rest.ClientRuntime": "1.8.0",
2323
"Newtonsoft.Json": "7.0.1",
2424
"System.Collections": "4.0.11-beta-23516",
2525
"System.Collections.Concurrent": "4.0.11-beta-23516",
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
new: create
2+
ResourceGroup: group

src/CLU/Commands.ResourceManager.Cmdlets/Implementation/FindAzureResourceGroupCmdlet.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ namespace Microsoft.Azure.Commands.ResourceManager.Cmdlets.Implementation
2929
public class FindAzureResourceGroupCmdlet : ResourceManagerCmdletBase
3030
{
3131
[Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The tag filter for the OData query. The expected format is @{Name = 'tagName'} or @{Name = 'tagName'; Value = 'tagValue'}.")]
32+
[Alias("t")]
3233
public Hashtable Tag { get; set; }
3334

3435
/// <summary>

src/CLU/Commands.ResourceManager.Cmdlets/Implementation/GetAzureResourceGroupDeploymentOperationCmdlet.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,23 +31,25 @@ public class GetAzureResourceGroupDeploymentOperationCmdlet : ResourceManagerCmd
3131
/// <summary>
3232
/// Gets or sets the resource group name parameter.
3333
/// </summary>
34-
[Alias("Name")]
3534
[Parameter(Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The deployment name.")]
3635
[ValidateNotNullOrEmpty]
36+
[Alias("Name","n")]
3737
public string DeploymentName { get; set; }
3838

3939
/// <summary>
4040
/// Gets or sets the subscription id parameter.
4141
/// </summary>
4242
[Parameter(Mandatory = false, ValueFromPipeline = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The subscription to use.")]
4343
[ValidateNotNullOrEmpty]
44+
[Alias("s", "id")]
4445
public Guid? SubscriptionId { get; set; }
4546

4647
/// <summary>
4748
/// Gets or sets the resource group name parameter.
4849
/// </summary>
4950
[Parameter(Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The resource group name.")]
5051
[ValidateNotNullOrEmpty]
52+
[Alias("group", "g")]
5153
public string ResourceGroupName { get; set; }
5254

5355
/// <summary>

src/CLU/Commands.ResourceManager.Cmdlets/Implementation/InvokeAzureResourceActionCmdlet.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,17 +28,17 @@ public sealed class InvokAzureResourceActionCmdlet : ResourceManipulationCmdletB
2828
/// <summary>
2929
/// Gets or sets the property object.
3030
/// </summary>
31-
[Alias("Object")]
3231
[Parameter(Mandatory = false, HelpMessage = "A hash table which represents resource properties.")]
3332
[ValidateNotNullOrEmpty]
33+
[Alias("Object")]
3434
public Hashtable Parameters { get; set; }
3535

3636
/// <summary>
3737
/// Gets or sets the property object.
3838
/// </summary>
39-
[Alias("ActionName")]
4039
[Parameter(Mandatory = true, HelpMessage = "The name of the action to invoke.")]
4140
[ValidateNotNullOrEmpty]
41+
[Alias("ActionName","a")]
4242
public string Action { get; set; }
4343

4444
/// <summary>

src/CLU/Commands.ResourceManager.Cmdlets/Implementation/Lock/GetAzureResourceLockCmdlet.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,14 +29,14 @@ public class GetAzureResourceLockCmdlet : ResourceLockManagementCmdletBase
2929
/// <summary>
3030
/// Gets or sets the extension resource name parameter.
3131
/// </summary>
32-
[Alias("ExtensionResourceName")]
3332
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.ResourceGroupLevelLock, Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3433
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.ResourceGroupResourceLevelLock, Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3534
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.ScopeLevelLock, Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3635
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.SubscriptionLevelLock, Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3736
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.SubscriptionResourceLevelLock, Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3837
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.TenantResourceLevelLock, Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3938
[ValidateNotNullOrEmpty]
39+
[Alias("ExtensionResourceName", "name", "n")]
4040
public string LockName { get; set; }
4141

4242
/// <summary>

src/CLU/Commands.ResourceManager.Cmdlets/Implementation/Lock/NewAzureResourceLockCmdlet.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,14 +28,14 @@ public class NewAzureResourceLockCmdlet : ResourceLockManagementCmdletBase
2828
/// <summary>
2929
/// Gets or sets the extension resource name parameter.
3030
/// </summary>
31-
[Alias("ExtensionResourceName")]
3231
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.ResourceGroupLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3332
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.ResourceGroupResourceLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3433
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.ScopeLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3534
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.SubscriptionLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3635
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.SubscriptionResourceLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3736
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.TenantResourceLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3837
[ValidateNotNullOrEmpty]
38+
[Alias("ExtensionResourceName", "name", "n")]
3939
public string LockName { get; set; }
4040

4141
/// <summary>
@@ -58,6 +58,7 @@ public class NewAzureResourceLockCmdlet : ResourceLockManagementCmdletBase
5858
/// Gets or sets the force parameter.
5959
/// </summary>
6060
[Parameter(Mandatory = false, HelpMessage = "Do not ask for confirmation.")]
61+
[Alias("f")]
6162
public SwitchParameter Force { get; set; }
6263

6364
/// <summary>

src/CLU/Commands.ResourceManager.Cmdlets/Implementation/Lock/RemoveAzureResourceLockCmdlet.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,20 +26,21 @@ public class RemoveAzureResourceLockCmdlet : ResourceLockManagementCmdletBase
2626
/// <summary>
2727
/// Gets or sets the extension resource name parameter.
2828
/// </summary>
29-
[Alias("ExtensionResourceName")]
3029
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.ResourceGroupLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3130
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.ResourceGroupResourceLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3231
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.ScopeLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3332
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.SubscriptionLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3433
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.SubscriptionResourceLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3534
[Parameter(ParameterSetName = ResourceLockManagementCmdletBase.TenantResourceLevelLock, Mandatory = true, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the lock.")]
3635
[ValidateNotNullOrEmpty]
36+
[Alias("ExtensionResourceName", "name", "n")]
3737
public string LockName { get; set; }
3838

3939
/// <summary>
4040
/// Gets or sets the force parameter.
4141
/// </summary>
4242
[Parameter(Mandatory = false, HelpMessage = "Do not ask for confirmation.")]
43+
[Alias("f")]
4344
public SwitchParameter Force { get; set; }
4445

4546
/// <summary>

0 commit comments

Comments
 (0)