From d82e75e86c8d1555aaa6415034aff215633fe7f2 Mon Sep 17 00:00:00 2001 From: Johannes Sixt Date: Sun, 9 Aug 2009 18:02:55 +0200 Subject: [PATCH] t0001-init: split the existence test from the permission test The test for correct permissions after init created a deep directory must be guarded by POSIXPERM. But testing that the deep dirctory exists is good even on platforms that do not provide the POSIXPERM prerequiste. Signed-off-by: Johannes Sixt Signed-off-by: Junio C Hamano --- t/t0001-init.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/t/t0001-init.sh b/t/t0001-init.sh index 07e011d9ef..5386504790 100755 --- a/t/t0001-init.sh +++ b/t/t0001-init.sh @@ -244,6 +244,12 @@ test_expect_success 'init recreates a new bare directory' ' test_expect_success 'init creates a new deep directory' ' rm -fr newdir && + git init newdir/a/b/c && + test -d newdir/a/b/c/.git/refs +' + +test_expect_success POSIXPERM 'init creates a new deep directory (umask vs. shared)' ' + rm -fr newdir && ( # Leading directories should honor umask while # the repository itself should follow "shared" -- 2.11.4.GIT