summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 74d2004)
raw | patch | inline | side by side (parent: 74d2004)
author | Junio C Hamano <junkio@cox.net> | |
Tue, 19 Dec 2006 09:14:35 +0000 (01:14 -0800) | ||
committer | Junio C Hamano <junkio@cox.net> | |
Tue, 19 Dec 2006 09:14:35 +0000 (01:14 -0800) |
This reverts commit 74d20040cafdced657efbf49795183d209a3a07b.
Version from Johannes to introduce GIT_TEMPLATE_DIR is simpler,
although I unconsciously stayed away from introducing yet another
environment variable.
Version from Johannes to introduce GIT_TEMPLATE_DIR is simpler,
although I unconsciously stayed away from introducing yet another
environment variable.
index a79c77af391bce1a209a793ac8ce75b02023fe2d..74f5c2a5755c8d29045498031c0bc3721a00b9c7 100755 (executable)
--- a/t/t4116-apply-reverse.sh
+++ b/t/t4116-apply-reverse.sh
git tar-tree initial initial | tar xf - &&
(
- cd initial && git_init_db && git add .
+ cd initial && git init-db && git add .
) &&
git tar-tree second second | tar xf - &&
(
- cd second && git_init_db && git add .
+ cd second && git init-db && git add .
)
'
diff --git a/t/t5300-pack-object.sh b/t/t5300-pack-object.sh
index 8a8152b2577693ec98dfe9d81d1b9784ceb24881..de45ac4e0fcea5b7acab245af9876b58ec1ccea3 100755 (executable)
--- a/t/t5300-pack-object.sh
+++ b/t/t5300-pack-object.sh
'unpack without delta' \
"GIT_OBJECT_DIRECTORY=.git2/objects &&
export GIT_OBJECT_DIRECTORY &&
- git_init_db &&
+ git-init-db &&
git-unpack-objects -n <test-1-${packname_1}.pack &&
git-unpack-objects <test-1-${packname_1}.pack"
'unpack with delta' \
'GIT_OBJECT_DIRECTORY=.git2/objects &&
export GIT_OBJECT_DIRECTORY &&
- git_init_db &&
+ git-init-db &&
git-unpack-objects -n <test-2-${packname_2}.pack &&
git-unpack-objects <test-2-${packname_2}.pack'
'use packed objects' \
'GIT_OBJECT_DIRECTORY=.git2/objects &&
export GIT_OBJECT_DIRECTORY &&
- git_init_db &&
+ git-init-db &&
cp test-1-${packname_1}.pack test-1-${packname_1}.idx .git2/objects/pack && {
git-diff-tree --root -p $commit &&
while read object
diff --git a/t/t5400-send-pack.sh b/t/t5400-send-pack.sh
index 901da8c4a9181a720b9308e74e06031ae9c2d7ae..28744b35e10602cf5076fbf5c62b3e767a847c0c 100755 (executable)
--- a/t/t5400-send-pack.sh
+++ b/t/t5400-send-pack.sh
parent=$commit || return 1
done &&
git-update-ref HEAD "$commit" &&
- git_clone -l ./. victim &&
+ git-clone -l ./. victim &&
cd victim &&
git-log &&
cd .. &&
diff --git a/t/t5500-fetch-pack.sh b/t/t5500-fetch-pack.sh
index 61e2a55311b13da3577c767280b40f5cc6a6d518..f7625a6f4634da4b78c90defdc0a302c8ea4e231 100755 (executable)
--- a/t/t5500-fetch-pack.sh
+++ b/t/t5500-fetch-pack.sh
(
mkdir client &&
cd client &&
- git_init_db 2>> log2.txt
+ git-init-db 2>> log2.txt
)
add A1
diff --git a/t/t5510-fetch.sh b/t/t5510-fetch.sh
index e2e8c894f977f65dbb1085129dac2c2e56b0a318..a11ab0ad41a006f9f20d8ec6172d34e6c7f92d41 100755 (executable)
--- a/t/t5510-fetch.sh
+++ b/t/t5510-fetch.sh
git commit -a -m original'
test_expect_success "clone and setup child repos" '
- git_clone . one &&
+ git clone . one &&
cd one &&
echo >file updated by one &&
git commit -a -m "updated by one" &&
cd .. &&
- git_clone . two &&
+ git clone . two &&
cd two &&
git repo-config branch.master.remote one &&
{
echo "Pull: refs/heads/master:refs/heads/one"
} >.git/remotes/one
cd .. &&
- git_clone . three &&
+ git clone . three &&
cd three &&
git repo-config branch.master.remote two &&
git repo-config branch.master.merge refs/heads/one &&
mkdir four &&
cd four &&
- git_init_db &&
+ git init-db &&
git fetch .. :track &&
git show-ref --verify refs/tags/anno &&
diff --git a/t/t5520-pull.sh b/t/t5520-pull.sh
index 66ef92f41f41e6b195f7936fbcac4a2a9c8dd946..f841574573545fa333e00b6815ba0df7d6931273 100755 (executable)
--- a/t/t5520-pull.sh
+++ b/t/t5520-pull.sh
test_expect_success 'pulling into void' '
mkdir cloned &&
cd cloned &&
- git_init_db &&
+ git init-db &&
git pull ..
'
index 1913a12d717fbf7362357e6e07254c364bb3e912..041be04f5ceed683f2b4959b119cde4e055ed6e4 100755 (executable)
test_expect_failure \
'clone of non-existent source should fail' \
- 'git_clone foo bar'
+ 'git-clone foo bar'
test_expect_failure \
'failed clone should not leave a directory' \
# current path not to the target dir
test_expect_failure \
'clone of non-existent (relative to $PWD) source should fail' \
- 'git_clone ../foo baz'
+ 'git-clone ../foo baz'
test_expect_success \
'clone should work now that source exists' \
- 'git_clone foo bar'
+ 'git-clone foo bar'
test_expect_success \
'successfull clone must leave the directory' \
index 52dab2d484fa84b4f766d176c6d78952732d8f5b..dd9caad1c2a34a6721aafa1840916a5a7471ece8 100755 (executable)
cd "$base_dir"
test_expect_success 'preparing second repository' \
-'git_clone A B && cd B &&
+'git clone A B && cd B &&
echo second > file2 &&
git add file2 &&
git commit -m addition &&
cd "$base_dir"
test_expect_success 'cloning with reference' \
-'git_clone -l -s --reference B A C'
+'git clone -l -s --reference B A C'
cd "$base_dir"
index 3c43554c69335463d1ec1cb0f186db15fb35067d..b9f6d9636313c29cb9d9553ca908e623fdefd179 100755 (executable)
cd "$base_dir"
test_expect_success 'preparing second repository' \
-'git_clone -l -s A B && cd B &&
+'git clone -l -s A B && cd B &&
echo "foo bar" > file2 &&
git add file2 &&
git commit -m "next commit" file2 &&
cd "$base_dir"
test_expect_success 'preparing third repository' \
-'git_clone -l -s B C && cd C &&
+'git clone -l -s B C && cd C &&
echo "Goodbye, cruel world" > file3 &&
git add file3 &&
git commit -m "one more" file3 &&
cd "$base_dir"
test_expect_failure 'creating too deep nesting' \
-'git_clone -l -s C D &&
-git_clone -l -s D E &&
-git_clone -l -s E F &&
-git_clone -l -s F G &&
-git_clone -l -s G H &&
+'git clone -l -s C D &&
+git clone -l -s D E &&
+git clone -l -s E F &&
+git clone -l -s F G &&
+git clone -l -s G H &&
cd H &&
test_valid_repo'
diff --git a/t/t7001-mv.sh b/t/t7001-mv.sh
index ae597e80dd917001add9f3608490a0067aa1a1a3..2f4ff82e149c497d79583f6b431b29d597e4a1ae 100755 (executable)
--- a/t/t7001-mv.sh
+++ b/t/t7001-mv.sh
test_expect_success "Michael Cassar's test case" '
rm -fr .git papers partA &&
- git_init_db &&
+ git init-db &&
mkdir -p papers/unsorted papers/all-papers partA &&
echo a > papers/unsorted/Thesis.pdf &&
echo b > partA/outline.txt &&
test_expect_success "Sergey Vlasov's test case" '
rm -fr .git &&
- git_init_db &&
+ git init-db &&
mkdir ab &&
date >ab.c &&
date >ab/d &&
diff --git a/t/test-lib.sh b/t/test-lib.sh
index 7e9149751e87831a1529d49ac909e1a26ff9568b..ac7be769b4d4f04908a64592a5c3ad8c43c27e60 100755 (executable)
--- a/t/test-lib.sh
+++ b/t/test-lib.sh
cd "$owd"
}
-# Many tests do init-db and clone but they must be told about the freshly
-# built templates.
-git_init_db () {
- git init-db --template="$GIT_EXEC_PATH/templates/blt/" "$@"
-}
-
-git_clone () {
- git clone --template="$GIT_EXEC_PATH/templates/blt/" "$@"
-}
-
test_done () {
trap - exit
case "$test_failure" in