tests/functions/Get-D365InstalledService.Tests.ps1

Describe "Get-D365InstalledService 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 Get-D365InstalledService).ParameterSets.Name | Should -Be 'Default'
        }
        
        It 'Should habe the expected parameter Path' {
            $parameter = (Get-Command Get-D365InstalledService).Parameters['Path']
            $parameter.Name | Should -Be 'Path'
            $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 $False
            $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 -
        Default -Path
        #>

    }

}