azure-powershell icon indicating copy to clipboard operation
azure-powershell copied to clipboard

Network Test Coverage

Open maddieclayton opened this issue 8 years ago • 8 comments

Many cmdlets in the Network module are missing tests or do not fully test the functionality of the cmdlet. This is blocking the addition of -AsJob for these cmdlets because we cannot add tests for this functionality of the -AsJob parameter. Once the tests are updated to fully cover these cmdlets, the -AsJob parameter can be added (details here).

Cmdlets that need improved test coverage:

  • [ ] Get-AzureRmVpnClientPackage: Asserts commented out.
  • [ ] Remove-AzureRmVirtualNetworkGatewayConnection: Not actually testing if connection is deleted.
  • [ ] Get-AzureRmExpressRouteCircuitARPTable: No asserts for cmdlet.
  • [ ] Get-AzureRmExpressRouteCircuitRouteTableSummary: No asserts for cmdlet.
  • [ ] Get-AzureRmExpressRouteCircuitRouteTable: No asserts for cmdlet.

Additional work related to this issue

  • [ ] Add AsJob parameter to each cmdlet with improved testing.

Cmdlets without coverage (by team, upd. 12/13/2018)

pgtm

  • [ ] Get-AzureRmExpressRouteCircuitConnectionConfig
  • [ ] Get-AzureRmExpressRouteCrossConnection
  • [ ] Set-AzureRMExpressRouteCrossConnection
  • [ ] Get-AzureRMExpressRouteCrossConnectionArpTable
  • [ ] Get-AzureRMExpressRouteCrossConnectionRouteTable
  • [ ] Get-AzureRMExpressRouteCrossConnectionRouteTableSummary
  • [ ] Add-AzureRmExpressRouteCrossConnectionPeering
  • [ ] Get-AzureRmExpressRouteCrossConnectionPeering
  • [ ] Remove-AzureRmExpressRouteCrossConnectionPeering

sdnnrp

  • [ ] Get-AzureRmInterfaceEndpoint - can't tests without New cmdlet, ETA for fixes from owning team - February 2019

Peering tests (skipped due to test framework constraints)

  • [ ] Add-AzureVirtualNetworkPeering
  • [ ] Get-AzureVirtualNetworkPeering
  • [ ] Set-AzureVirtualNetworkPeering
  • [ ] Remove-AzureVirtualNetworkPeering

firewall

  • [ ] AzureFirewallNetworkRuleProtocolHelper - need tests for cases such as $rule.AddProtocol(“http”)

maddieclayton avatar Jan 03 '18 20:01 maddieclayton

SDN Remove-AzureRmRouteFilter: No test currently Get-AzureRmEffectiveNetworkSecurityGroup: Runs the get but doesn't check its contents Remove-AzureRmApplicationSecurityGroup: Doesn't actually test if the Security Group is deleted.

App Gateway Remove-AzureRmApplicationGateway: No asserts for cmdlet. Start-AzureRmApplicationGateway: No tests for cmdlet.

NetWatcher Get-NetworkWatcherTroubleshooting: Test skipped, no asserts for cmdlet.

Express route Get-AzureRmExpressRouteCircuitARPTable: No asserts for cmdlet. Get-AzureRmExpressRouteCircuitRouteTableSummary: No asserts for cmdlet. Get-AzureRmExpressRouteCircuitRouteTable: No asserts for cmdlet.

Brooklyn Set-AzureRmVirtualNetworkGatewayDefaultSite: Test being skipped. Set-AzureRmVirtualNetworkGatewayVpnClientConfig: Test being skipped. Remove-AzureRmVirtualNetworkGatewayDefaultSite: Test being skipped. Resize-AzureRmVirtualNetworkGateway: Test being skipped. Remove-AzureRmVpnClientRevokedCertificate: Test being skipped. Remove-AzureRmVpnClientRootCertificate: Test being skipped. New-AzureRmVpnClientConfiguration: Test being skipped. Get-AzureRmVpnClientPackage: Test being skipped, Asserts commented out. Add-AzureRmVpnClientRootCertificate: Test being skipped. Add-AzureRmVpnClientRevokedCertificate: Test being skipped. Remove-AzureRmVirtualNetworkGatewayConnection: Not actually testing if connection is deleted. Set-AzureRmVirtualNetworkGatewayConnectionSharedKey: Test skipped, asserts commented out. Reset-AzureRmVirtualNetworkGatewayConnectionSharedKey: Test skipped, asserts commented out.

MikhailTryakhov avatar Aug 06 '18 15:08 MikhailTryakhov

Guys please mark items as fixed in description of the incident

MikhailTryakhov avatar Aug 06 '18 15:08 MikhailTryakhov

@MikhailTryakhov "Remove-AzureRmApplicationSecurityGroup: Doesn't actually test if the Security Group is deleted." is SDNNRP's test

Also, the tests with the following cmdlets are no longer skipped

  • Set-AzureRmVirtualNetworkGatewayDefaultSite: Test being skipped.
  • Set-AzureRmVirtualNetworkGatewayVpnClientConfig: Test being skipped.
  • Remove-AzureRmVirtualNetworkGatewayDefaultSite: Test being skipped.
  • Resize-AzureRmVirtualNetworkGateway: Test being skipped.
  • Add-AzureRmVpnClientRootCertificate: Test being skipped.
  • Remove-AzureRmVpnClientRootCertificate: Test being skipped.
  • New-AzureRmVpnClientConfiguration: Test being skipped.
  • Remove-AzureRmVpnClientRevokedCertificate: Test being skipped.
  • Add-AzureRmVpnClientRevokedCertificate: Test being skipped.

anton-evseev avatar Aug 07 '18 13:08 anton-evseev

SDN: Remove-AzureRmRouteFilter: No test currently Get-AzureRmEffectiveNetworkSecurityGroup: No test Remove-AzureRmApplicationSecurityGroup: Doesn't actually test if the Security Group is deleted.

Brroklyn Get-AzureRmVpnClientPackage: Asserts commented out. Remove-AzureRmVirtualNetworkGatewayConnection: Not actually testing if connection is deleted. Set-AzureRmVirtualNetworkGatewayConnectionSharedKey: Asserts commented out. Reset-AzureRmVirtualNetworkGatewayConnectionSharedKey: Asserts commented out.

NetWatcher Get-NetworkWatcherTroubleshooting: Test skipped, no asserts for cmdlet.

Express Route Get-AzureRmExpressRouteCircuitARPTable: No asserts for cmdlet. Get-AzureRmExpressRouteCircuitRouteTableSummary: No asserts for cmdlet. Get-AzureRmExpressRouteCircuitRouteTable: No asserts for cmdlet.

Application Gateway Remove-AzureRmApplicationGateway: No asserts for cmdlet. Start-AzureRmApplicationGateway: No tests for cmdlet.

MikhailTryakhov avatar Aug 09 '18 12:08 MikhailTryakhov

@number213 @EvgenyAgafonchikov please update

MikhailTryakhov avatar Nov 30 '18 18:11 MikhailTryakhov

Updated issue details, added list of cmdlets without test coverage, split by teams


pgtm

  • [ ] Get-AzureRmExpressRouteCircuitConnectionConfig
  • [ ] Get-AzureRmExpressRouteCrossConnection
  • [ ] Set-AzureRMExpressRouteCrossConnection
  • [ ] Get-AzureRMExpressRouteCrossConnectionArpTable
  • [ ] Get-AzureRMExpressRouteCrossConnectionRouteTable
  • [ ] Get-AzureRMExpressRouteCrossConnectionRouteTableSummary
  • [ ] Add-AzureRmExpressRouteCrossConnectionPeering
  • [ ] Get-AzureRmExpressRouteCrossConnectionPeering
  • [ ] Remove-AzureRmExpressRouteCrossConnectionPeering

sdnnrp

  • [ ] Get-AzureRmInterfaceEndpoint - can't tests without New cmdlet, ETA for fixes from owning team - February 2019

Peering tests (skipped due to test framework constraints)

  • [ ] Add-AzureVirtualNetworkPeering
  • [ ] Get-AzureVirtualNetworkPeering
  • [ ] Set-AzureVirtualNetworkPeering
  • [ ] Remove-AzureVirtualNetworkPeering

firewall

  • [ ] AzureFirewallNetworkRuleProtocolHelper - need tests for cases such as $rule.AddProtocol(“http”)

anton-evseev avatar Dec 13 '18 09:12 anton-evseev

Will take a look at Brooklyn related command lets.

Nilambari avatar Nov 21 '19 22:11 Nilambari

:bell: Routing this issue to @act-quality-productivity-squad.