Increase code coverage #22

Merged
OCram85 merged 34 commits from dev into master 2018-03-21 12:16:09 +01:00
2 changed files with 3 additions and 2 deletions
Showing only changes of commit 1a6a861ad1 - Show all commits

View File

@ -89,8 +89,8 @@ Could not find the required {0} called {1}. Please install the required {0} to r
else {
if ($StopIfFails) {
Write-Error -Message $Message -ErrorAction Stop -Category NotInstalled
return $false
}
return $false
}
}

View File

@ -32,7 +32,8 @@ Describe "Test-ModuleName" {
}
Context "Working with PSSnapins" {
It "Loading first PSSnaping should not throw " {
$Snap = Get-PSSnapin -Registered | Select-Object -First 1
$Snap = Get-PSSnapin -Registered
$Snap
{ $loaded = Test-Module -Name $Snap.Name -Type PSSnapin } | Should -Not -Throw
Remove-PSSnapin -Name $Snap.Name
}