index 843a5013b96c675a629bd7f738eca220861e6ff8..5f4cfb6bbaa2b8aa8d24d4db44e04725fa6eed40 100755 (executable)
--- a/t/t9100-git-svn-basic.sh
+++ b/t/t9100-git-svn-basic.sh
name='try a deep --rmdir with a commit'
test_expect_success "$name" '
- git checkout -f -b mybranch remotes/git-svn &&
+ git checkout -f -b mybranch ${remotes_git_svn} &&
mv dir/a/b/c/d/e/file dir/file &&
cp dir/file file &&
git update-index --add --remove dir/a/b/c/d/e/file dir/file file &&
git commit -m "$name" &&
git-svn set-tree --find-copies-harder --rmdir \
- remotes/git-svn..mybranch &&
+ ${remotes_git_svn}..mybranch &&
svn up "$SVN_TREE" &&
test -d "$SVN_TREE"/dir && test ! -d "$SVN_TREE"/dir/a'
git update-index --add dir/file/file &&
git commit -m '$name' &&
test_must_fail git-svn set-tree --find-copies-harder --rmdir \
- remotes/git-svn..mybranch" || true
+ ${remotes_git_svn}..mybranch" || true
name='detect node change from directory to file #1'
test_expect_success "$name" '
rm -rf dir "$GIT_DIR"/index &&
- git checkout -f -b mybranch2 remotes/git-svn &&
+ git checkout -f -b mybranch2 ${remotes_git_svn} &&
mv bar/zzz zzz &&
rm -rf bar &&
mv zzz bar &&
git update-index --add -- bar &&
git commit -m "$name" &&
test_must_fail git-svn set-tree --find-copies-harder --rmdir \
- remotes/git-svn..mybranch2' || true
+ ${remotes_git_svn}..mybranch2' || true
name='detect node change from file to directory #2'
test_expect_success "$name" '
rm -f "$GIT_DIR"/index &&
- git checkout -f -b mybranch3 remotes/git-svn &&
+ git checkout -f -b mybranch3 ${remotes_git_svn} &&
rm bar/zzz &&
git update-index --remove bar/zzz &&
mkdir bar/zzz &&
git update-index --add bar/zzz/yyy &&
git commit -m "$name" &&
test_must_fail git-svn set-tree --find-copies-harder --rmdir \
- remotes/git-svn..mybranch3' || true
+ ${remotes_git_svn}..mybranch3' || true
name='detect node change from directory to file #2'
test_expect_success "$name" '
rm -f "$GIT_DIR"/index &&
- git checkout -f -b mybranch4 remotes/git-svn &&
+ git checkout -f -b mybranch4 ${remotes_git_svn} &&
rm -rf dir &&
git update-index --remove -- dir/file &&
touch dir &&
git update-index --add -- dir &&
git commit -m "$name" &&
test_must_fail git-svn set-tree --find-copies-harder --rmdir \
- remotes/git-svn..mybranch4' || true
+ ${remotes_git_svn}..mybranch4' || true
name='remove executable bit from a file'
test_expect_success "$name" '
rm -f "$GIT_DIR"/index &&
- git checkout -f -b mybranch5 remotes/git-svn &&
+ git checkout -f -b mybranch5 ${remotes_git_svn} &&
chmod -x exec.sh &&
git update-index exec.sh &&
git commit -m "$name" &&
git-svn set-tree --find-copies-harder --rmdir \
- remotes/git-svn..mybranch5 &&
+ ${remotes_git_svn}..mybranch5 &&
svn up "$SVN_TREE" &&
test ! -x "$SVN_TREE"/exec.sh'
git update-index exec.sh &&
git commit -m "$name" &&
git-svn set-tree --find-copies-harder --rmdir \
- remotes/git-svn..mybranch5 &&
+ ${remotes_git_svn}..mybranch5 &&
svn up "$SVN_TREE" &&
test -x "$SVN_TREE"/exec.sh'
git update-index exec.sh &&
git commit -m "$name" &&
git-svn set-tree --find-copies-harder --rmdir \
- remotes/git-svn..mybranch5 &&
+ ${remotes_git_svn}..mybranch5 &&
svn up "$SVN_TREE" &&
test -L "$SVN_TREE"/exec.sh'
git update-index --add bar/zzz exec-2.sh &&
git commit -m "$name" &&
git-svn set-tree --find-copies-harder --rmdir \
- remotes/git-svn..mybranch5 &&
+ ${remotes_git_svn}..mybranch5 &&
svn up "$SVN_TREE" &&
test -x "$SVN_TREE"/bar/zzz &&
test -L "$SVN_TREE"/exec-2.sh'
git update-index exec-2.sh &&
git commit -m "$name" &&
git-svn set-tree --find-copies-harder --rmdir \
- remotes/git-svn..mybranch5 &&
+ ${remotes_git_svn}..mybranch5 &&
svn up "$SVN_TREE" &&
test -f "$SVN_TREE"/exec-2.sh &&
test ! -L "$SVN_TREE"/exec-2.sh &&
export GIT_SVN_ID
test_expect_success "$name" \
'git-svn init "$svnrepo" && git-svn fetch &&
- git rev-list --pretty=raw remotes/git-svn | grep ^tree | uniq > a &&
+ git rev-list --pretty=raw ${remotes_git_svn} | grep ^tree | uniq > a &&
git rev-list --pretty=raw remotes/alt | grep ^tree | uniq > b &&
test_cmp a b'
test_expect_success 'exit if remote refs are ambigious' "
git config --add svn-remote.svn.fetch \
- bar:refs/remotes/git-svn &&
+ bar:refs/${remotes_git_svn} &&
test_must_fail git-svn migrate
"
svnadmin create "${PWD}/svnrepo2" &&
svn mkdir -m "mkdir bar" "${svnrepo}2/bar" &&
git config --unset svn-remote.svn.fetch \
- "^bar:refs/remotes/git-svn$" &&
+ "^bar:refs/${remotes_git_svn}$" &&
test_must_fail git-svn init "${svnrepo}2/bar"
'
git config --get svn-remote.svn.fetch \
"^bar:refs/remotes/bar$" &&
git config --get svn-remote.svn.fetch \
- "^:refs/remotes/git-svn$"
+ "^:refs/${remotes_git_svn}$"
'
test_expect_success 'able to dcommit to a subdirectory' "