Skip to content

Commit 5cc9d8d

Browse files
committed
code clean up
1 parent 3df3e2a commit 5cc9d8d

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

test/InstallPSResourceTests/InstallPSResourceContainerRegistryServer.Tests.ps1

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ Describe 'Test Install-PSResource for ACR scenarios' -tags 'CI' {
5050
Install-PSResource -Name $Name -Repository $ACRRepoName -ErrorVariable err -ErrorAction SilentlyContinue
5151
$err.Count | Should -BeGreaterThan 0
5252
$err[0].FullyQualifiedErrorId | Should -BeExactly "$ErrorId,Microsoft.PowerShell.PSResourceGet.Cmdlets.InstallPSResource"
53-
$res = Get-InstalledPSResource $testModuleName
53+
$res = Get-InstalledPSResource $testModuleName -ErrorAction SilentlyContinue
5454
$res | Should -BeNullOrEmpty
5555
}
5656

@@ -110,7 +110,7 @@ Describe 'Test Install-PSResource for ACR scenarios' -tags 'CI' {
110110

111111
It "Install resource where version specified is a prerelease version" {
112112
# the resource has version "1.0", but querying with any equivalent version should work
113-
Install-PSResource -Name $testModuleWith2DigitVersion -Version "1.5-alpha" -Prerelease -Repository $ACRRepoName -TrustRepository
113+
Install-PSResource -Name $testModuleWith2DigitVersion -Version "1.5-alpha" -Prerelease -Repository $ACRRepoName -TrustRepository -Verbose -Debug
114114
$res = Get-InstalledPSResource -Name $testModuleWith2DigitVersion
115115
$res | Should -Not -BeNullOrEmpty
116116
$res.Version | Should -Be "1.5"
@@ -126,7 +126,7 @@ Describe 'Test Install-PSResource for ACR scenarios' -tags 'CI' {
126126

127127
It "Should not install resource given nonexistent name" {
128128
Install-PSResource -Name "NonExistentModule" -Repository $ACRRepoName -TrustRepository -ErrorVariable err -ErrorAction SilentlyContinue
129-
$pkg = Get-InstalledPSResource "NonExistentModule"
129+
$pkg = Get-InstalledPSResource "NonExistentModule" -ErrorAction SilentlyContinue
130130
$pkg | Should -BeNullOrEmpty
131131
$err.Count | Should -BeGreaterThan 0
132132
$err[0].FullyQualifiedErrorId | Should -BeExactly "ResourceNotFound,Microsoft.PowerShell.PSResourceGet.Cmdlets.InstallPSResource"

test/SavePSResourceTests/SavePSResourceV3.Tests.ps1

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,6 @@ Describe 'Test HTTP Save-PSResource for V3 Server Protocol' -tags 'CI' {
156156
}
157157

158158
It "Save module and its dependencies" {
159-
$DebugPreference = 'Continue'
160159
$res = Save-PSResource 'TestModuleWithDependencyE' -Repository $NuGetGalleryName -TrustRepository -PassThru -Confirm:$false -Debug -Verbose
161160
$res.Length | Should -Be 4
162161
}

0 commit comments

Comments
 (0)