Skip to content

Commit

Permalink
[ubuntu] Change Add-AssertionOperator to Add-ShouldOperator (#3445)
Browse files Browse the repository at this point in the history
  • Loading branch information
miketimofeev authored May 24, 2021
1 parent 8dd6faf commit 39e317a
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions images/linux/scripts/helpers/Tests.Helpers.psm1
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,6 @@ function ShouldReturnZeroExitCode {
}
}

If (Get-Command -Name Add-AssertionOperator -ErrorAction SilentlyContinue) {
Add-AssertionOperator -Name ReturnZeroExitCode -InternalName ShouldReturnZeroExitCode -Test ${function:ShouldReturnZeroExitCode}
}

function ShouldMatchCommandOutput {
Param(
[String] $ActualValue,
Expand Down Expand Up @@ -102,7 +98,7 @@ function ShouldMatchCommandOutput {
}
}

If (Get-Command -Name Add-AssertionOperator -ErrorAction SilentlyContinue) {
Add-AssertionOperator -Name ReturnZeroExitCode -InternalName ShouldReturnZeroExitCode -Test ${function:ShouldReturnZeroExitCode}
Add-AssertionOperator -Name MatchCommandOutput -InternalName ShouldMatchCommandOutput -Test ${function:ShouldMatchCommandOutput}
}
If (Get-Command -Name Add-ShouldOperator -ErrorAction SilentlyContinue) {
Add-ShouldOperator -Name ReturnZeroExitCode -InternalName ShouldReturnZeroExitCode -Test ${function:ShouldReturnZeroExitCode}
Add-ShouldOperator -Name MatchCommandOutput -InternalName ShouldMatchCommandOutput -Test ${function:ShouldMatchCommandOutput}
}

0 comments on commit 39e317a

Please sign in to comment.