Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding Standard_Microsoft in Cdn Pricing sku #7210

Merged
merged 5 commits into from
Sep 12, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -125,6 +125,9 @@
<None Include="SessionRecords\Microsoft.Azure.Commands.Cdn.Test.ScenarioTests.ScenarioTest.ProfileTests\TestProfileGetResourceUsage.json">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
<None Include="SessionRecords\Microsoft.Azure.Commands.Cdn.Test.ScenarioTests.ScenarioTest.ProfileTests\TestSkuCreate.json">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
<None Include="SessionRecords\Microsoft.Azure.Commands.Cdn.Test.ScenarioTests.ScenarioTest.EndpointTests\TestEndpointResourceUsage.json">
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
</None>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,13 @@ public void TestProfileCrud()
TestController.NewInstance.RunPowerShellTest(_logger, "Test-ProfileCrud");
}

[Fact]
[Trait(Category.AcceptanceType, Category.CheckIn)]
public void TestSkuCreate()
{
TestController.NewInstance.RunPowerShellTest(_logger, "Test-SkuCreate");
}

[Fact]
[Trait(Category.AcceptanceType, Category.CheckIn)]
public void TestProfileCrudWithPiping()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,49 @@
# limitations under the License.
# ----------------------------------------------------------------------------------

<#
.SYNOPSIS
Create Profile with different Sku
#>
function Test-SkuCreate
{
$profileName = getAssetName
$resourceGroup = TestSetup-CreateResourceGroup
$profileLocation = "EastUS"
$profileSku = "Standard_Microsoft"
$createdProfile = New-AzureRmCdnProfile -ProfileName $profileName -ResourceGroupName $resourceGroup.ResourceGroupName -Location $profileLocation -Sku $profileSku

Assert-NotNull $createdProfile
Assert-AreEqual $profileName $createdProfile.Name
Assert-AreEqual $resourceGroup.ResourceGroupName $createdProfile.ResourceGroupName
Assert-AreEqual $profileSku $createdProfile.Sku.Name

$profileSku = "Standard_Verizon"
$profileName = getAssetName
$createdProfile = New-AzureRmCdnProfile -ProfileName $profileName -ResourceGroupName $resourceGroup.ResourceGroupName -Location $profileLocation -Sku $profileSku
Assert-NotNull $createdProfile
Assert-AreEqual $profileName $createdProfile.Name
Assert-AreEqual $resourceGroup.ResourceGroupName $createdProfile.ResourceGroupName
Assert-AreEqual $profileSku $createdProfile.Sku.Name

$profileSku = "Premium_Verizon"
$profileName = getAssetName
$createdProfile = New-AzureRmCdnProfile -ProfileName $profileName -ResourceGroupName $resourceGroup.ResourceGroupName -Location $profileLocation -Sku $profileSku
Assert-NotNull $createdProfile
Assert-AreEqual $profileName $createdProfile.Name
Assert-AreEqual $resourceGroup.ResourceGroupName $createdProfile.ResourceGroupName
Assert-AreEqual $profileSku $createdProfile.Sku.Name

$profileSku = "Standard_Akamai"
$profileName = getAssetName
$createdProfile = New-AzureRmCdnProfile -ProfileName $profileName -ResourceGroupName $resourceGroup.ResourceGroupName -Location $profileLocation -Sku $profileSku
Assert-NotNull $createdProfile
Assert-AreEqual $profileName $createdProfile.Name
Assert-AreEqual $resourceGroup.ResourceGroupName $createdProfile.ResourceGroupName
Assert-AreEqual $profileSku $createdProfile.Sku.Name

Remove-AzureRmResourceGroup -Name $resourceGroup.ResourceGroupName -Force
}
<#
.SYNOPSIS
Full Profile CRUD cycle
Expand Down

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions src/ResourceManager/Cdn/Commands.Cdn/ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
- Additional information about change #1
-->
## Current Release
* Added Standard_Microsoft in Cdn pricing sku.

## Version 5.0.5
* Fixed issue with default resource groups not being set.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ public enum PSSkuName
Premium_Verizon,
Custom_Verizon,
Standard_Akamai,
Standard_ChinaCdn
Standard_ChinaCdn,
Standard_Microsoft
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public class NewAzureRmCdnProfile : AzureCdnCmdletBase
/// <summary>
/// The pricing sku name of the profile.
/// </summary>
[Parameter(Mandatory = true, HelpMessage = "The pricing sku name of the Azure CDN profile. Valid values are StandardVerizon, StandardAkamai, and PremiumVerizon.")]
[Parameter(Mandatory = true, HelpMessage = "The pricing sku name of the Azure CDN profile. Valid values are StandardVerizon, StandardAkamai, Standard_Microsoft and PremiumVerizon.")]
public PSSkuName Sku { get; set; }

/// <summary>
Expand Down