From e60ee4cab83805d64c51fc7733dec6c890056d8c Mon Sep 17 00:00:00 2001 From: OCram85 Date: Tue, 28 Jun 2022 11:51:43 +0200 Subject: [PATCH] wip --- src/Item/New-CredentialStoreItem.Tests.ps1 | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/src/Item/New-CredentialStoreItem.Tests.ps1 b/src/Item/New-CredentialStoreItem.Tests.ps1 index 099476f..02d1188 100644 --- a/src/Item/New-CredentialStoreItem.Tests.ps1 +++ b/src/Item/New-CredentialStoreItem.Tests.ps1 @@ -1,7 +1,12 @@ [Diagnostics.CodeAnalysis.SuppressMessageAttribute( 'PSAvoidUsingConvertToSecureStringWithPlainText', '', - Justification = 'justification' + Justification = 'just used in pester tests.' +)] +[Diagnostics.CodeAnalysis.SuppressMessageAttribute( + 'PSProvideCommentHelp', + '', + Justification = 'no need in internal pester helpers.' )] param () @@ -53,7 +58,7 @@ Describe "New-CredentialStoreItem" { New-CredentialStoreItem -Shared -Path $tmpCS -RemoteHost $RemoteHost -Credential $mycreds } | Should -Not -Throw $tmpCS = Get-Content -Path $tmpCS -Raw | ConvertFrom-Json - $res = Get-Member -InputObject $tmpCS -Name $RemoteHost -Membertype Properties + $res = Get-Member -InputObject $tmpCS -Name $RemoteHost -MemberType Properties $res.Name | Should -Be $RemoteHost } It "Adds Item with identifier to shared store" { @@ -65,8 +70,8 @@ Describe "New-CredentialStoreItem" { $mycreds = [PSCredential]::new($UserName, $Password) $RemoteHost = "foobar2" $StoreItemParam = @{ - Shared = $true - Path = $tmpCS + Shared = $true + Path = $tmpCS RemoteHost = $RemoteHost Credential = $mycreds identifier = 'Foo'