]> git.ipfire.org Git - thirdparty/git.git/commit - t/test-lib.sh
test-lib.sh: do not barf under --debug at the end of the test
authorJunio C Hamano <gitster@pobox.com>
Tue, 25 Apr 2017 06:39:47 +0000 (23:39 -0700)
committerJunio C Hamano <gitster@pobox.com>
Tue, 25 Apr 2017 06:39:47 +0000 (23:39 -0700)
commit4d0912a206a32e9763424363617e8425f049f344
tree95d0682c16b961e6c87d5fbe5ef05f45c8945ff9
parentdf4c0d1a7927e17e7944ec24fa94468eee979f6e
test-lib.sh: do not barf under --debug at the end of the test

The original did "does $remove_trash exist?  Then go one level above
and remove it".  There was no problem under "--debug", where
the variable is left empty, as the first "test -d $remove_trash" would
have said "No, it doesn't".

With the check implemented in the previous step, we'd always get an
error under "--debug".

Noticed-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/test-lib.sh