Public/Export/Export-ISEThemeFile.Tests.ps1

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
$function = Get-Command -Name Export-ISEThemeFile
Describe 'Export-ISEThemeFile Tests' {
   Context 'Parameters for Export-ISEThemeFile'{
It 'Has a parameter called ISETheme' {
            $function.Parameters.Keys.Contains('ISETheme') | Should Be 'True'
            }
        It 'ISETheme Parameter is Correctly Identified as being Mandatory' {
            $function.Parameters.ISETheme.Attributes.Mandatory | Should be 'False'
            }
        It 'ISETheme Parameter is of String Type' {
            $function.Parameters.ISETheme.ParameterType.FullName | Should be 'System.String'
            }

It 'Has a parameter called SaveToISE' {
            $function.Parameters.Keys.Contains('SaveToISE') | Should Be 'True'
            }
        It 'SaveToISE Parameter is Correctly Identified as being Mandatory' {
            $function.Parameters.SaveToISE.Attributes.Mandatory | Should be 'False'
            }
        It 'SaveToISE Parameter is of SwitchParameter Type' {
            $function.Parameters.SaveToISE.ParameterType.FullName | Should be 'System.Management.Automation.SwitchParameter'
            }

      }

 }