diff --git a/Tests/Public/Connect-ZertoServer.Tests.ps1 b/Tests/Public/Connect-ZertoServer.Tests.ps1 index 6d6e185..f417346 100644 --- a/Tests/Public/Connect-ZertoServer.Tests.ps1 +++ b/Tests/Public/Connect-ZertoServer.Tests.ps1 @@ -1,6 +1,6 @@ #Requires -Modules Pester $global:here = (Split-Path -Parent $PSCommandPath) -$global:function = ((Split-Path -leaf $PSCommandPath).Split('.'))[0] +$global:function = ((Split-Path -Leaf $PSCommandPath).Split('.'))[0] Describe $global:function -Tag 'Unit', 'Source', 'Built' { BeforeAll { @@ -45,6 +45,16 @@ Describe $global:function -Tag 'Unit', 'Source', 'Built' { { Connect-ZertoServer -zertoServer -credential 1234 } | Should -Throw { Connect-ZertoServer -zertoServer -credential $(@{Username = "zerto\build"; Password = 'SecureString' }) } | Should -Throw } + + It "has a switch parameter to return the headers" { + Get-Command $global:function | Should -HaveParameter returnHeaders + Get-Command $global:function | Should -HaveParameter returnHeaders -Type Switch + } + + It "has a switch parameter to auto reauthorize the session" { + Get-Command $global:function | Should -HaveParameter autoReconnect + Get-Command $global:function | Should -HaveParameter autoReconnect -Type Switch + } } InModuleScope -ModuleName ZertoApiWrapper {