Skip to content
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 @@ -206,6 +206,14 @@ public void TestAzureFirewallPolicySizeProperty()
TestRunner.RunTestScript("Test-AzureFirewallPolicySizeProperty");
}

[Fact]
[Trait(Category.AcceptanceType, Category.CheckIn)]
[Trait(Category.Owner, NrpTeamAlias.azurefirewall)]
public void TestAzureFirewallPolicyAfcManaged()
{
TestRunner.RunTestScript("Test-AzureFirewallPolicyAfcManaged");
}

[Fact]
[Trait(Category.AcceptanceType, Category.CheckIn)]
[Trait(Category.Owner, NrpTeamAlias.azurefirewall)]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2060,6 +2060,31 @@ function Test-AzureFirewallPolicySizeProperty {
}
}

function Test-AzureFirewallPolicyAfcManaged {
# Setup
$rgname = Get-ResourceGroupName
$azureFirewallPolicyName = Get-ResourceName
$location = "westus2"

try {
# Create the resource group
New-AzResourceGroup -Name $rgname -Location $location

# Create AzureFirewallPolicy
New-AzFirewallPolicy -Name $azureFirewallPolicyName -ResourceGroupName $rgname -Location $location

# Get AzureFirewallPolicy
$getAzureFirewallPolicy = Get-AzFirewallPolicy -Name $azureFirewallPolicyName -ResourceGroupName $rgname

# AfcManaged is a read-only property surfaced from the RP; a standard policy is not AFC-managed
Assert-Null $getAzureFirewallPolicy.AfcManaged
Comment thread
saisujithreddym marked this conversation as resolved.
}
finally {
# Cleanup
Clean-ResourceGroup $rgname
}
}

function Test-AzureFirewallPolicyRuleCollectionGroupSizeProperty {
# Setup
$rgname = Get-ResourceGroupName
Expand Down
Loading