Skip to content

Commit 9df2ef1

Browse files
committed
Update integration tests for Get-SqlDscConfigurationOption to assert correct values for Agent XPs configuration option
1 parent f090d96 commit 9df2ef1

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

tests/Integration/Commands/Get-SqlDscConfigurationOption.Integration.Tests.ps1

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -79,8 +79,8 @@ Describe 'Get-SqlDscConfigurationOption' -Tag @('Integration_SQL2017', 'Integrat
7979
$result | Should -BeOfType 'PSCustomObject'
8080
$result.PSTypeNames[0] | Should -Be 'SqlDsc.ConfigurationOption'
8181
$result.Name | Should -Be 'Agent XPs'
82-
$result.RunValue | Should -Be 0
83-
$result.ConfigValue | Should -Be 0
82+
$result.RunValue | Should -Be 1
83+
$result.ConfigValue | Should -Be 1
8484
$result.Minimum | Should -Be 0
8585
$result.Maximum | Should -Be 1
8686
$result.IsDynamic | Should -BeTrue
@@ -103,7 +103,7 @@ Describe 'Get-SqlDscConfigurationOption' -Tag @('Integration_SQL2017', 'Integrat
103103
$result = Get-SqlDscConfigurationOption -ServerObject $script:serverObject -Name '*XP*'
104104

105105
@($result).Count | Should -BeGreaterOrEqual 1
106-
$result | Where-Object { $_.Name -eq 'Agent XPs' } | Should -Not -BeNullOrEmpty
106+
$result | Where-Object -FilterScript { $_.Name -eq 'Agent XPs' } | Should -Not -BeNullOrEmpty
107107
}
108108
}
109109

@@ -114,8 +114,8 @@ Describe 'Get-SqlDscConfigurationOption' -Tag @('Integration_SQL2017', 'Integrat
114114
$result | Should -Not -BeNullOrEmpty
115115
$result | Should -BeOfType 'Microsoft.SqlServer.Management.Smo.ConfigProperty'
116116
$result.DisplayName | Should -Be 'Agent XPs'
117-
$result.RunValue | Should -Be 0
118-
$result.ConfigValue | Should -Be 0
117+
$result.RunValue | Should -Be 1
118+
$result.ConfigValue | Should -Be 1
119119
}
120120
}
121121

@@ -137,7 +137,7 @@ Describe 'Get-SqlDscConfigurationOption' -Tag @('Integration_SQL2017', 'Integrat
137137
$result | Should -Not -BeNullOrEmpty
138138
$result | Should -BeOfType 'PSCustomObject'
139139
$result.Name | Should -Be 'Agent XPs'
140-
$result.RunValue | Should -Be 0
140+
$result.RunValue | Should -Be 1
141141
}
142142
}
143143
}

0 commit comments

Comments
 (0)