Skip to content

Commit

Permalink
fix UT
Browse files Browse the repository at this point in the history
  • Loading branch information
fchastanet committed Dec 5, 2023
1 parent 5b37261 commit 6465869
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/_binaries/Git/upgradeGithubRelease.bats
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,14 @@ function Git::upgradeGithubRelease::noArg { #@test
assert_output --partial "ERROR - Command upgradeGithubRelease - Argument 'targetFile' should be provided at least 1 time(s)"
}

function Git::upgradeGithubRelease::1Arg { #@test
run "${binDir}/upgradeGithubRelease" arg1 2>&1
function Git::upgradeGithubRelease::1ArgNotWritable { #@test
run "${binDir}/upgradeGithubRelease" /notWritable/arg1 2>&1
assert_failure 1
assert_output --partial "FATAL - File /notWritable/arg1 is not writable"
}

function Git::upgradeGithubRelease::1ArgWritable { #@test
run "${binDir}/upgradeGithubRelease" /tmp/arg1 2>&1
assert_failure 1
assert_output --partial "ERROR - Command upgradeGithubRelease - Argument 'githubUrlPattern' should be provided at least 1 time(s)"
}
Expand Down

0 comments on commit 6465869

Please sign in to comment.