Skip to content

Commit

Permalink
tests: TestMountPasswordIncorrect: better error on wrong exit code
Browse files Browse the repository at this point in the history
Report that exit code is wrong when the
exit code is wrong.
  • Loading branch information
rfjakob committed Dec 11, 2023
1 parent 15118e6 commit 6fbe61d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tests/cli/cli_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -407,7 +407,7 @@ func TestMountPasswordIncorrect(t *testing.T) {
err := test_helpers.Mount(cDir, pDir, false, "-extpass", "echo WRONG", "-wpanic=false", "-ctlsock", ctlSock)
exitCode := test_helpers.ExtractCmdExitCode(err)
if exitCode != exitcodes.PasswordIncorrect {
t.Errorf("want=%d, got=%d", exitcodes.PasswordIncorrect, exitCode)
t.Errorf("wrong exit code: want=%d, have=%d", exitcodes.PasswordIncorrect, exitCode)
}
if _, err := os.Stat(ctlSock); err == nil {
t.Errorf("socket file %q left behind", ctlSock)
Expand Down

0 comments on commit 6fbe61d

Please sign in to comment.