Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to Import PowerSTIG 4.4.0 Due to cyclic dependency Error #617

Merged
merged 18 commits into from
May 19, 2020
Merged
Prev Previous commit
Next Next commit
Updated tests
  • Loading branch information
erjenkin committed May 14, 2020
commit cc6f6bbc2c85a0f98268bf23c03689bfb4109351
7 changes: 6 additions & 1 deletion Tests/Integration/Module/PowerStig.Integration.tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,15 @@ Describe "$moduleName module" {
(Get-Module -Name $script:modulePath -ListAvailable).ModuleType | Should Be 'Script'
}

$compositeModulePaths = (Get-ChildItem -Path $script:dscCompositePath -Include '*schema.psm1' -Recurse).FullName
$compositeModulePaths = (Get-ChildItem -Path $script:dscCompositePath -Include '*schema.psm1' -exclude "*Vsphere*" -Recurse).FullName
$manifestRequiredModules = (Import-PowerShellDataFile -Path $script:modulePath).RequiredModules |
ForEach-Object -Process {[pscustomobject]$PSItem}

#$vsphereRequiredModuleVersion = (Get-Content (Get-Childitem -path $script:moduleroot -Include "*ModuleHelper.ps1" -recurse) |
# Select-String -pattern "(?<=Dsc'; ModuleVersion = ')(.*\w)").Matches.Value
#$vsphereRequiredModule = New-Object -TypeName psobject –Property @{ModuleName = "Vmware.VsphereDsc";ModuleVersion = $vsphereRequiredModuleVersion}
#$manifestRequiredModules += $vsphereRequiredModule

foreach ($compositeModule in $compositeModulePaths)
{
$dscModuleInfo = Get-DscResourceModuleInfo -Path $compositeModule
Expand Down