Skip to content

Commit

Permalink
t9104: fix test for following larger parents
Browse files Browse the repository at this point in the history
This test is special for several reasons:
It ends with a "true" statement, which should be a no-op.
It is not because the &&-chain is broken right before it.

Also, looking at what the test intended to test according to
7f578c5 (git-svn: --follow-parent now works on sub-directories of larger
branches, 2007-01-24)
it is not clear how it would achieve that with the given steps.

Amend the test to include the second svn id to be tested for, and
change the tested refs to the ones which are to be expected, and which
make the test pass.

Signed-off-by: Michael J Gruber <git@drmicha.warpmail.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
Michael J Gruber authored and Junio C Hamano committed Mar 20, 2015
1 parent 8bafd20 commit b7a06e0
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions t/t9104-git-svn-follow-parent.sh
Original file line number Diff line number Diff line change
Expand Up @@ -72,16 +72,18 @@ test_expect_success 'follow larger parent' '
svn import -m "import a larger parent" import "$svnrepo"/larger-parent &&
svn cp -m "hi" "$svnrepo"/larger-parent "$svnrepo"/another-larger &&
git svn init --minimize-url -i larger \
"$svnrepo"/another-larger/trunk/thunk/bump/thud &&
"$svnrepo"/larger-parent/trunk/thunk/bump/thud &&
git svn fetch -i larger &&
git svn init --minimize-url -i larger-parent \
"$svnrepo"/another-larger/trunk/thunk/bump/thud &&
git svn fetch -i larger-parent &&
git rev-parse --verify refs/remotes/larger &&
git rev-parse --verify \
refs/remotes/larger-parent/trunk/thunk/bump/thud &&
refs/remotes/larger-parent &&
test "`git merge-base \
refs/remotes/larger-parent/trunk/thunk/bump/thud \
refs/remotes/larger-parent \
refs/remotes/larger`" = \
"`git rev-parse refs/remotes/larger`"
true
'

test_expect_success 'follow higher-level parent' '
Expand Down

0 comments on commit b7a06e0

Please sign in to comment.