tests/functions/Set-D365OfflineAuthenticationAdminEmail.Tests.ps1
Describe "Set-D365OfflineAuthenticationAdminEmail Unit Tests" -Tag "Unit" { BeforeAll { # Place here all things needed to prepare for the tests } AfterAll { # Here is where all the cleanup tasks go } Describe "Ensuring unchanged command signature" { It "should have the expected parameter sets" { (Get-Command Set-D365OfflineAuthenticationAdminEmail).ParameterSets.Name | Should -Be 'Default' } It 'Should have the expected parameter Email' { $parameter = (Get-Command Set-D365OfflineAuthenticationAdminEmail).Parameters['Email'] $parameter.Name | Should -Be 'Email' $parameter.ParameterType.ToString() | Should -Be System.String $parameter.IsDynamic | Should -Be $False $parameter.ParameterSets.Keys | Should -Be 'Default' $parameter.ParameterSets.Keys | Should -Contain 'Default' $parameter.ParameterSets['Default'].IsMandatory | Should -Be $True $parameter.ParameterSets['Default'].Position | Should -Be 1 $parameter.ParameterSets['Default'].ValueFromPipeline | Should -Be $False $parameter.ParameterSets['Default'].ValueFromPipelineByPropertyName | Should -Be $False $parameter.ParameterSets['Default'].ValueFromRemainingArguments | Should -Be $False } } Describe "Testing parameterset Default" { <# Default -Email Default -Email #> } } |