File tree Expand file tree Collapse file tree 3 files changed +36
-2
lines changed
src/PSDesiredStateConfiguration Expand file tree Collapse file tree 3 files changed +36
-2
lines changed Original file line number Diff line number Diff line change 99RootModule = ' PSDesiredStateConfiguration.psm1'
1010
1111# Version number of this module.
12- moduleVersion = ' 2.0.2 '
12+ moduleVersion = ' 2.0.3 '
1313
1414# Supported PSEditions
1515CompatiblePSEditions = @ (' Core' )
Original file line number Diff line number Diff line change @@ -1890,7 +1890,7 @@ function Configuration
18901890 return $null
18911891 }
18921892
1893- $moduleToImport | Forearch - Object - Process {
1893+ $moduleToImport | Foreach -Object - Process {
18941894 $versionToUse = $_.Version
18951895 if ( [string ]::IsNullOrEmpty($versionToUse ))
18961896 {
Original file line number Diff line number Diff line change 1+ # Copyright (c) Microsoft Corporation. All rights reserved.
2+ # Licensed under the MIT License.
3+ Describe " DSC MOF Compilation" - tags " CI" {
4+ BeforeAll {
5+ $module = Get-Module PowerShellGet - ListAvailable | Sort-Object - Property Version - Descending | Select-Object - First 1
6+
7+ $psGetModuleVersion = $module.Version.ToString ()
8+ }
9+
10+ It " Should be able to compile a MOF using PSModule resource" {
11+ if ($IsLinux ) {
12+ Set-ItResult - Pending - Because " https://github.com/PowerShell/PowerShellGet/pull/529"
13+ }
14+
15+ Write-Verbose " DSC_HOME: ${env: DSC_HOME} " - verbose
16+ [Scriptblock ]::Create(@"
17+ configuration DSCTestConfig
18+ {
19+ Import-DscResource -ModuleName PowerShellGet -ModuleVersion $psGetModuleVersion
20+ Node "localhost" {
21+ PSModule f1
22+ {
23+ Name = 'PsDscResources'
24+ InstallationPolicy = 'Trusted'
25+ }
26+ }
27+ }
28+
29+ DSCTestConfig -OutputPath TestDrive:\DscTestConfig2
30+ "@ ) | Should -Not - Throw
31+
32+ " TestDrive:\DscTestConfig2\localhost.mof" | Should - Exist
33+ }
34+ }
You can’t perform that action at this time.
0 commit comments