From 2ccd2027b012f481018b9a95929fa8df6ce1d33f Mon Sep 17 00:00:00 2001 From: Alex Riesen Date: Thu, 5 Jan 2006 12:57:36 +0100 Subject: trivial: check, if t/trash directory was successfully created and was successfully entered. Otherwise git-init-db will create it directly in the working directory (t/) which can be dangerous. Signed-off-by: Alex Riesen Signed-off-by: Junio C Hamano diff --git a/t/test-lib.sh b/t/test-lib.sh index a97d259..7534a76 100755 --- a/t/test-lib.sh +++ b/t/test-lib.sh @@ -195,7 +195,7 @@ test -d ../templates/blt || { test=trash rm -fr "$test" mkdir "$test" -cd "$test" +cd "$test" || error "Cannot setup test environment" "$GIT_EXEC_PATH/git" init-db --template=../../templates/blt/ 2>/dev/null || error "cannot run git init-db -- have you built things yet?" -- cgit v0.10.2-6-g49f6