Skip to content

Commit a669f26

Browse files
committed
Fixed CustomDomainTests to use a domain that didn't belong to me personally. :)
1 parent 884daea commit a669f26

File tree

3 files changed

+1476
-533
lines changed

3 files changed

+1476
-533
lines changed

src/ResourceManager/Cdn/Commands.Cdn.Test/ScenarioTests/CustomDomainTests.ps1

Lines changed: 6 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,8 @@ function Test-CustomDomainGetRemoveWithRunningEndpoint
5353
Assert-ThrowsContains { Remove-AzureRmCdnCustomDomain -CustomDomainName $customDomainName -EndpointName $endpointName -ProfileName $profileName -ResourceGroupName $resourceGroup.ResourceGroupName -Confirm:$false} "does not exist"
5454

5555
Assert-ThrowsContains { Get-AzureRmCdnCustomDomain -CustomDomainName $customDomainName -EndpointName $endpointName -ProfileName $profileName -ResourceGroupName $resourceGroup.ResourceGroupName } "NotFound"
56+
57+
Remove-AzureRmResourceGroup -Name $resourceGroup.ResourceGroupName -Force
5658
}
5759

5860
<#
@@ -61,23 +63,8 @@ Gets and removes custom domain with stopped endpoint
6163
#>
6264
function Test-CustomDomainGetRemoveWithStoppedEndpoint
6365
{
64-
<#
65-
$endpointName = "sdktest-3d96e37e-79bd-440d-a84b-d71a8bb3bed6"
66-
$hostName = "sdktest-aef2f35e-01ca-4230-add5-5075b1506915.azureedge-test.net"
67-
68-
- casoper
69-
#>
70-
71-
<#
72-
73-
So apparently the above endpoint name already exists, because it bombs when I try
74-
to create it. I don't have access to DNS for azureedge-test.net, so I can't add
75-
a CNAME pointed to a different endpoint. So I'm using my own domain to record this one...
76-
77-
#>
78-
79-
$endpointName = "camtest" #belongs to casoper (see above)
80-
$hostName = "cdn.camthegeek.com" #belongs to casoper (see above)
66+
$endpointName = "sdktest-b0939e74-75ba-4558-afe6-edc5c19ea713"
67+
$hostName = "sdktest-d8163a47-2912-4b95-8453-1588ca2d014f.azureedge-test.net"
8168

8269
$customDomainName = getAssetName
8370

@@ -114,4 +101,6 @@ function Test-CustomDomainGetRemoveWithStoppedEndpoint
114101
Assert-ThrowsContains { Remove-AzureRmCdnCustomDomain -CustomDomainName $customDomainName -EndpointName $endpointName -ProfileName $profileName -ResourceGroupName $resourceGroup.ResourceGroupName -Confirm:$false} "does not exist"
115102

116103
Assert-ThrowsContains { Get-AzureRmCdnCustomDomain -CustomDomainName $customDomainName -EndpointName $endpointName -ProfileName $profileName -ResourceGroupName $resourceGroup.ResourceGroupName } "NotFound"
104+
105+
Remove-AzureRmResourceGroup -Name $resourceGroup.ResourceGroupName -Force
117106
}

0 commit comments

Comments
 (0)