diff --git a/t/test-lib.sh b/t/test-lib.sh
index 268b26c959692f8f575fb088143a92c4785b1214..7c2a8ba77d312c3196767969a39687bfb12f74c9 100644 (file)
--- a/t/test-lib.sh
+++ b/t/test-lib.sh
test_must_fail () {
"$@"
- test $? -gt 0 -a $? -le 128
+ test $? -gt 0 -a $? -le 129
}
# test_cmp is a helper function to compare actual and expected output.
# Test repository
test=trash
-rm -fr "$test"
+rm -fr "$test" || {
+ trap - exit
+ echo >&5 "FATAL: Cannot prepare test area"
+ exit 1
+}
+
test_create_repo $test
cd "$test"