From be56ab3406ed327ab27ef5b84052dc011fcc8ce0 Mon Sep 17 00:00:00 2001 From: Marius Storhaug Date: Tue, 7 Jul 2026 17:43:10 +0200 Subject: [PATCH 1/2] Require Pester 6.x in test files --- tests/PSCredential.Tests.ps1 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tests/PSCredential.Tests.ps1 b/tests/PSCredential.Tests.ps1 index 117a34d..3f71154 100644 --- a/tests/PSCredential.Tests.ps1 +++ b/tests/PSCredential.Tests.ps1 @@ -1,4 +1,6 @@ -[Diagnostics.CodeAnalysis.SuppressMessageAttribute( +#Requires -Modules @{ ModuleName = 'Pester'; ModuleVersion = '6.0.0'; MaximumVersion = '6.*'; GUID = 'a699dea5-2c73-4616-a270-1f7abb777e71' } + +[Diagnostics.CodeAnalysis.SuppressMessageAttribute( 'PSAvoidUsingConvertToSecureStringWithPlainText', '', Justification = 'Tests only; not for production code' )] From 97254d7215ce0b8aabc72e0acfe7cbf04195ce7a Mon Sep 17 00:00:00 2001 From: Marius Storhaug Date: Tue, 7 Jul 2026 21:12:25 +0200 Subject: [PATCH 2/2] Drop the GUID from the Pester requirement The GUID pins module identity (precise pinning), a stricter control than the lock-to-major risk appetite. Keep only the version range. --- tests/PSCredential.Tests.ps1 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/PSCredential.Tests.ps1 b/tests/PSCredential.Tests.ps1 index 3f71154..ff0c57a 100644 --- a/tests/PSCredential.Tests.ps1 +++ b/tests/PSCredential.Tests.ps1 @@ -1,4 +1,4 @@ -#Requires -Modules @{ ModuleName = 'Pester'; ModuleVersion = '6.0.0'; MaximumVersion = '6.*'; GUID = 'a699dea5-2c73-4616-a270-1f7abb777e71' } +#Requires -Modules @{ ModuleName = 'Pester'; ModuleVersion = '6.0.0'; MaximumVersion = '6.*' } [Diagnostics.CodeAnalysis.SuppressMessageAttribute( 'PSAvoidUsingConvertToSecureStringWithPlainText', '',