Skip to content

Commit 508f480

Browse files
authored
Merge pull request #3161 from hyonholee/stack-dev
Add VM ScaleSet cmdlets and tests
2 parents cdea0ea + d4c8cc1 commit 508f480

File tree

56 files changed

+19072
-3
lines changed

Some content is hidden

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

56 files changed

+19072
-3
lines changed

src/ResourceManager/Compute/AzureRM.Compute.psd1

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,13 +55,14 @@ ScriptsToProcess = @()
5555

5656
# Type files (.ps1xml) to be loaded when importing this module
5757
TypesToProcess = @(
58-
'.\Microsoft.Azure.Commands.Compute.Types.ps1xml'
58+
'.\Microsoft.Azure.Commands.Compute.Types.ps1xml'
5959
)
6060

6161
# Format files (.ps1xml) to be loaded when importing this module
6262
FormatsToProcess = @(
63-
'.\Microsoft.Azure.Commands.Compute.format.ps1xml',
64-
'.\Microsoft.Azure.Commands.Compute.format.generated.ps1xml'
63+
'.\Microsoft.Azure.Commands.Compute.format.ps1xml',
64+
'.\Microsoft.Azure.Commands.Compute.format.generated.ps1xml',
65+
'.\Generated\Microsoft.Azure.Commands.Compute.Automation.format.generated.ps1xml'
6566
)
6667

6768
# Modules to import as nested modules of the module specified in ModuleToProcess

src/ResourceManager/Compute/Commands.Compute.Test/Commands.Compute.Test.csproj

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -165,6 +165,7 @@
165165
<Compile Include="ScenarioTests\DiagnosticsExtensionTests.cs" />
166166
<Compile Include="ScenarioTests\DscExtensionTests.cs" />
167167
<Compile Include="ScenarioTests\VirtualMachineBootDiagnosticsTests.cs" />
168+
<Compile Include="ScenarioTests\VirtualMachineScaleSetTests.cs" />
168169
<Compile Include="ScenarioTests\VMDynamicTests.cs" />
169170
<Compile Include="ScenarioTests\VirtualMachineProfileTests.cs" />
170171
<Compile Include="ScenarioTests\AvailabilitySetTests.cs" />
@@ -244,6 +245,9 @@
244245
<None Include="ScenarioTests\DiagnosticsExtensionTests.ps1">
245246
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
246247
</None>
248+
<None Include="ScenarioTests\VirtualMachineScaleSetTests.ps1">
249+
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
250+
</None>
247251
<None Include="ScenarioTests\VMDynamicTests.ps1">
248252
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
249253
</None>
@@ -342,6 +346,12 @@
342346
<None Include="SessionRecords\Microsoft.Azure.Commands.Compute.Test.ScenarioTests.VirtualMachineProfileTests\TestVirtualMachineProfileWithoutAUC.json">
343347
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
344348
</None>
349+
<None Include="SessionRecords\Microsoft.Azure.Commands.Compute.Test.ScenarioTests.VirtualMachineScaleSetTests\TestVirtualMachineScaleSet.json">
350+
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
351+
</None>
352+
<None Include="SessionRecords\Microsoft.Azure.Commands.Compute.Test.ScenarioTests.VirtualMachineScaleSetTests\TestVirtualMachineScaleSetReimageUpdate.json">
353+
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
354+
</None>
345355
<None Include="SessionRecords\Microsoft.Azure.Commands.Compute.Test.ScenarioTests.VirtualMachineTests\TestGetVMSizeFromAllLocations.json">
346356
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
347357
</None>
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
// ----------------------------------------------------------------------------------
2+
//
3+
// Copyright Microsoft Corporation
4+
// Licensed under the Apache License, Version 2.0 (the "License");
5+
// you may not use this file except in compliance with the License.
6+
// You may obtain a copy of the License at
7+
// http://www.apache.org/licenses/LICENSE-2.0
8+
// Unless required by applicable law or agreed to in writing, software
9+
// distributed under the License is distributed on an "AS IS" BASIS,
10+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11+
// See the License for the specific language governing permissions and
12+
// limitations under the License.
13+
// ----------------------------------------------------------------------------------
14+
15+
using Microsoft.WindowsAzure.Commands.ScenarioTest;
16+
using Xunit;
17+
18+
namespace Microsoft.Azure.Commands.Compute.Test.ScenarioTests
19+
{
20+
public partial class VirtualMachineScaleSetTests
21+
{
22+
[Fact]
23+
[Trait(Category.AcceptanceType, Category.CheckIn)]
24+
public void TestVirtualMachineScaleSet()
25+
{
26+
ComputeTestController.NewInstance.RunPsTest("Test-VirtualMachineScaleSet");
27+
}
28+
29+
[Fact]
30+
[Trait(Category.AcceptanceType, Category.CheckIn)]
31+
public void TestVirtualMachineScaleSetReimageUpdate()
32+
{
33+
ComputeTestController.NewInstance.RunPsTest("Test-VirtualMachineScaleSetReimageUpdate");
34+
}
35+
}
36+
}

src/ResourceManager/Compute/Commands.Compute.Test/ScenarioTests/VirtualMachineScaleSetTests.ps1

Lines changed: 387 additions & 0 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)