From 01cef3c26b0a8fffd373deb4d57a5a48b59f4d62 Mon Sep 17 00:00:00 2001 From: Joel Bennett Date: Sun, 5 Jun 2022 23:29:44 -0400 Subject: [PATCH 1/2] Stop re-importing metadata --- Source/Header/param.ps1 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Source/Header/param.ps1 b/Source/Header/param.ps1 index f4f9e3c..05e214c 100644 --- a/Source/Header/param.ps1 +++ b/Source/Header/param.ps1 @@ -6,4 +6,6 @@ param( $MachineData ) -Import-Module Metadata -Force -Args @($Converters) -Verbose:$false -Global \ No newline at end of file +if ($Converters) { + Add-MetadataConverter $Converters +} \ No newline at end of file From 1cee0608fee4fcd62969f41f3e835c5b86b6cb4a Mon Sep 17 00:00:00 2001 From: Joel Bennett Date: Mon, 6 Jun 2022 00:13:39 -0400 Subject: [PATCH 2/2] Try to fix the Linux tests --- Specs/Configuration.Steps.ps1 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Specs/Configuration.Steps.ps1 b/Specs/Configuration.Steps.ps1 index 8c0e301..f63b476 100644 --- a/Specs/Configuration.Steps.ps1 +++ b/Specs/Configuration.Steps.ps1 @@ -102,6 +102,8 @@ Given 'the configuration module is imported with testing paths on Linux:' { Set-Variable IsLinux $True -Force -Option ReadOnly, AllScope -Scope Global Import-Module $ModuleBase/Configuration.psd1 -Scope Global Set-Variable IsLinux $False -Force -Option ReadOnly, AllScope -Scope Global + } else { + Import-Module $ModuleBase/Configuration.psd1 -Scope Global } Update-Metadata -Path $ModuleBase/Configuration.psd1 -PropertyName 'PrivateData.PathOverride.MachineData' -Value ""