diff --git a/Tests/Public/Get-ZAAlertAggregation.Tests.ps1 b/Tests/Public/Get-ZAAlertAggregation.Tests.ps1 deleted file mode 100644 index f5816b6..0000000 --- a/Tests/Public/Get-ZAAlertAggregation.Tests.ps1 +++ /dev/null @@ -1,19 +0,0 @@ -#Requires -Modules Pester -$moduleFileName = "ZertoApiWrapper.psd1" -$here = (Split-Path -Parent $MyInvocation.MyCommand.Path).Replace("Tests", "ZertoApiWrapper") -$sut = (Split-Path -Leaf $MyInvocation.MyCommand.Path).Replace(".Tests.", ".") -$file = Get-ChildItem "$here\$sut" -$modulePath = $here -replace "Public", "" -$moduleFile = Get-ChildItem "$modulePath\$moduleFileName" -Get-Module -Name ZertoApiWrapper | Remove-Module -Force -Import-Module $moduleFile -Force - -Describe $file.BaseName -Tag 'Unit' { - - It "is valid Powershell (Has no script errors)" { - $contents = Get-Content -Path $file -ErrorAction Stop - $errors = $null - $null = [System.Management.Automation.PSParser]::Tokenize($contents, [ref]$errors) - $errors | Should -HaveCount 0 - } -} diff --git a/ZertoApiWrapper/Public/Get-ZAAlertAggregation.ps1 b/ZertoApiWrapper/Public/Get-ZAAlertAggregation.ps1 deleted file mode 100644 index 7b82559..0000000 --- a/ZertoApiWrapper/Public/Get-ZAAlertAggregation.ps1 +++ /dev/null @@ -1,20 +0,0 @@ -<# .ExternalHelp ./en-us/ZertoApiWrapper-help.xml #> -function Get-ZAAlertAggeration { - [cmdletbinding()] - param( - [Parameter( - HelpMessage = "The ZORG identifier by which to filter the alert count. If the ZORG identifier is omitted, retrieves all alerts sorted by entity and by type." - )] - [ValidateNotNullOrEmpty()] - [string]$zOrgIdentifier - ) - $uri = "monitoring/alerts" - if ( -not [String]::IsNullorEmpty($zOrgIdentifier) ) { - $filterTable = @{"zOrgIdentifier" = $zOrgIdentifier } - $filterString = Get-ZertoApiFilter -filterTable $filterTable - $uri = "{0}{1}&format=aggregations" -f $uri, $filterString - } else { - $uri = "{0}?format=aggregations" -f $uri - } - Invoke-ZARestRequest -uri $uri -}