t / t9104-git-svn-follow-parent.shon commit Merge branch 'master' of git://git.kernel.org/pub/scm/git/git (6758391)
   1#!/bin/sh
   2#
   3# Copyright (c) 2006 Eric Wong
   4#
   5
   6test_description='git-svn --follow-parent fetching'
   7. ./lib-git-svn.sh
   8
   9test_expect_success 'initialize repo' "
  10        mkdir import &&
  11        cd import &&
  12        mkdir -p trunk &&
  13        echo hello > trunk/readme &&
  14        svn import -m 'initial' . $svnrepo &&
  15        cd .. &&
  16        svn co $svnrepo wc &&
  17        cd wc &&
  18        echo world >> trunk/readme &&
  19        svn commit -m 'another commit' &&
  20        svn up &&
  21        svn mv -m 'rename to thunk' trunk thunk &&
  22        svn up &&
  23        echo goodbye >> thunk/readme &&
  24        svn commit -m 'bye now' &&
  25        cd ..
  26        "
  27
  28test_expect_success 'init and fetch --follow-parent a moved directory' "
  29        git-svn init -i thunk $svnrepo/thunk &&
  30        git-svn fetch --follow-parent -i thunk &&
  31        git-rev-parse --verify refs/remotes/trunk &&
  32        test '$?' -eq '0'
  33        "
  34
  35test_debug 'gitk --all &'
  36
  37test_done