diff --git a/t/t9001-send-email.sh b/t/t9001-send-email.sh index e80eacbb1b..776769fe0d 100755 --- a/t/t9001-send-email.sh +++ b/t/t9001-send-email.sh @@ -1966,11 +1966,11 @@ test_expect_success $PREREQ 'invoke hook' ' # Verify error message when a patch is rejected by the hook sed -e "s/add master/x/" ../0001-add-master.patch >../another.patch && - git send-email \ + test_must_fail git send-email \ --from="Example " \ --to=nobody@example.com \ --smtp-server="$(pwd)/../fake.sendmail" \ - ../another.patch 2>err + ../another.patch 2>err && test_i18ngrep "rejected by sendemail-validate hook" err ) '