diff options
author | Johannes Sixt <j6t@kdbg.org> | 2009-08-09 18:02:55 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2009-08-09 10:43:24 -0700 |
commit | d82e75e86c8d1555aaa6415034aff215633fe7f2 (patch) | |
tree | ee723f1e8b56c263f139c20f441fd6a367a43972 /t/t0001-init.sh | |
parent | 7d53a07a2833116cdf52ca256375c6b37f4d6b46 (diff) | |
download | git-d82e75e86c8d1555aaa6415034aff215633fe7f2.tar.gz |
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 <j6t@kdbg.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t0001-init.sh')
-rwxr-xr-x | t/t0001-init.sh | 6 |
1 files changed, 6 insertions, 0 deletions
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" |