You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
_cmdletPassedIn.WriteWarning($"Unable to resolve repository source '{Repository.Uri.LocalPath}' due to exception: {e.Message}");
277
+
_cmdletPassedIn.WriteWarning($"Unable to resolve repository '{Repository.Name}' with source '{Repository.Uri.LocalPath}' due to exception: {e.Message}");
_cmdletPassedIn.WriteWarning($"Unable to resolve repository '{Repository.Name}' with source '{Repository.Uri.LocalPath}' due to exception: {e.Message}");
_cmdletPassedIn.WriteWarning($"Unable to resolve repository '{Repository.Name}' with source '{Repository.Uri.LocalPath}' due to exception: {e.Message}");
It "Find should not silently fail if network connection to local private repository cannot be established and remainder repositories should be searched"
$WarningVar[0] | Should -Contain $privateRepo.Uri.LocalPath
358
+
$res.Name| Should -Contain $testModuleName
359
+
$res.Version| Should -Be "1.0.0"
360
+
}
361
+
362
+
It "Find should not silently fail if network connection to local private repository cannot be established and package version was provided and remainder repositories should be searched"
Copy file name to clipboardExpand all lines: test/InstallPSResourceTests/InstallPSResourceLocal.Tests.ps1
+21Lines changed: 21 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -16,6 +16,7 @@ Describe 'Test Install-PSResource for local repositories' -tags 'CI' {
16
16
BeforeAll {
17
17
$localRepo="psgettestlocal"
18
18
$localUNCRepo="psgettestlocal3"
19
+
$localPrivateRepo="psgettestlocal5"
19
20
$localNupkgRepo="localNupkgRepo"
20
21
$testModuleName="test_local_mod"
21
22
$testModuleName2="test_local_mod2"
@@ -296,4 +297,24 @@ Describe 'Test Install-PSResource for local repositories' -tags 'CI' {
296
297
$pkg.Name| Should -Be $nupkgName
297
298
$pkg.Version| Should -Be $nupkgVersion
298
299
}
300
+
301
+
It "Install should not silently fail if network connection to local private repository cannot be established and remainder repositories should be searched"
$WarningVar[0] | Should -Contain $privateRepo.Uri.LocalPath
307
+
$res.Name| Should -Contain $testModuleName
308
+
$res.Version| Should -Be "1.0.0"
309
+
}
310
+
311
+
It "Install should not silently fail if network connection to local private repository cannot be established and package version was provided and remainder repositories should be searched"
0 commit comments