Clean up approxidate() in preparation for fixes
[git.git] / t / t9104-git-svn-follow-parent.sh
blob01488ff78acd8324a04a3f0c5e4788e60148a704
1 #!/bin/sh
3 # Copyright (c) 2006 Eric Wong
6 test_description='git-svn --follow-parent fetching'
7 . ./lib-git-svn.sh
9 if test -n "$GIT_SVN_NO_LIB" && test "$GIT_SVN_NO_LIB" -ne 0
10 then
11 echo 'Skipping: --follow-parent needs SVN libraries'
12 test_done
13 exit 0
16 test_expect_success 'initialize repo' "
17 mkdir import &&
18 cd import &&
19 mkdir -p trunk &&
20 echo hello > trunk/readme &&
21 svn import -m 'initial' . $svnrepo &&
22 cd .. &&
23 svn co $svnrepo wc &&
24 cd wc &&
25 echo world >> trunk/readme &&
26 svn commit -m 'another commit' &&
27 svn up &&
28 svn mv -m 'rename to thunk' trunk thunk &&
29 svn up &&
30 echo goodbye >> thunk/readme &&
31 svn commit -m 'bye now' &&
32 cd ..
35 test_expect_success 'init and fetch --follow-parent a moved directory' "
36 git-svn init -i thunk $svnrepo/thunk &&
37 git-svn fetch --follow-parent -i thunk &&
38 git-rev-parse --verify refs/remotes/trunk &&
39 test '$?' -eq '0'
42 test_debug 'gitk --all &'
44 test_done