lib-git-svn.sh 709 字节
Newer Older
E
Eric Wong 已提交
1 2 3
. ./test-lib.sh

if test -n "$NO_SVN_TESTS"
4
then
E
Eric Wong 已提交
5 6 7
	test_expect_success 'skipping git-svn tests, NO_SVN_TESTS defined' :
	test_done
	exit
8 9 10
fi

GIT_DIR=$PWD/.git
11
GIT_SVN_DIR=$GIT_DIR/svn/git-svn
12
SVN_TREE=$GIT_SVN_DIR/svn-tree
13 14 15 16

svnadmin >/dev/null 2>&1
if test $? != 1
then
E
Eric Wong 已提交
17
    test_expect_success 'skipping git-svn tests, svnadmin not found' :
18 19 20 21 22 23 24
    test_done
    exit
fi

svn >/dev/null 2>&1
if test $? != 1
then
E
Eric Wong 已提交
25
    test_expect_success 'skipping git-svn tests, svn not found' :
26 27 28 29 30 31 32 33
    test_done
    exit
fi

svnrepo=$PWD/svnrepo

set -e

34 35 36 37 38 39 40
if svnadmin create --help | grep fs-type >/dev/null
then
	svnadmin create --fs-type fsfs "$svnrepo"
else
	svnadmin create "$svnrepo"
fi

41 42 43
svnrepo="file://$svnrepo/test-git-svn"