git-svn: --follow-parent tracks multi-parent paths

We can have a branch that was deleted, then re-added under the
same name but copied from another path, in which case we'll have
multiple parents (we don't want to break the original ref, nor
lose copypath info).

Add a test for this, too, of course.

Signed-off-by: Eric Wong <normalperson@yhbt.net>
This commit is contained in:
Eric Wong
2007-02-09 01:28:30 -08:00
parent e518192f3b
commit b9dffd8cad
2 changed files with 18 additions and 3 deletions

View File

@ -146,6 +146,13 @@ test_expect_success "track initial change if it was only made to parent" "
\"\`git rev-parse r9270-d~1\`\"
"
test_expect_success "track multi-parent paths" "
svn cp -m 'resurrect /glob' $svnrepo/r9270 $svnrepo/glob &&
git-svn multi-fetch --follow-parent &&
test \`git cat-file commit refs/remotes/glob | \
grep '^parent ' | wc -l\` -eq 2
"
test_expect_success "multi-fetch continues to work" "
git-svn multi-fetch --follow-parent
"