From: Colin Walters Date: Wed, 6 Dec 2017 01:55:13 +0000 (-0500) Subject: tests: Change test-corruption to use fatal() X-Git-Tag: archive/raspbian/2022.1-3+rpi1~1^2~4^2~28^2~27 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=d102cd7db00fca88af27cba73fe5b7a4fd8f8484;p=ostree.git tests: Change test-corruption to use fatal() It's clearer. Closes: #1364 Approved by: jlebon --- diff --git a/tests/test-corruption.sh b/tests/test-corruption.sh index 52a8189a..cb5e9c09 100755 --- a/tests/test-corruption.sh +++ b/tests/test-corruption.sh @@ -29,7 +29,9 @@ setup_test_repository "bare" $OSTREE checkout test2 checkout-test2 cd checkout-test2 chmod o+x firstfile -$OSTREE fsck -q && (echo 1>&2 "fsck unexpectedly succeeded"; exit 1) +if $OSTREE fsck -q; then + fatal "fsck unexpectedly succeeded" +fi chmod o-x firstfile $OSTREE fsck -q @@ -54,7 +56,9 @@ rm checkout-test2 -rf $OSTREE checkout test2 checkout-test2 cd checkout-test2 chmod o+x firstfile -$OSTREE fsck -q --delete && (echo 1>&2 "fsck unexpectedly succeeded"; exit 1) +if $OSTREE fsck -q --delete; then + fatal "fsck unexpectedly succeeded" +fi echo "ok chmod"