mirror of
https://github.com/git/git.git
synced 2024-11-16 14:04:52 +01:00
7b3fab877d
Some of the git-svn tests can fail on fast machines due to a race in Subversion: if a file is modified in the same second it was checked out (or in for that matter), Subversion will not consider it modified. This works around the problem by increasing the timestamp by one second before each commit. [jc: with "touch -r -d" replacement from Eric] Acked-by: Eric Wong <normalperson@yhbt.net> Signed-off-by: Michael Spang <mspang@uwaterloo.ca> Signed-off-by: Junio C Hamano <junkio@cox.net>
39 lines
831 B
Bash
Executable file
39 lines
831 B
Bash
Executable file
#!/bin/sh
|
|
#
|
|
# Copyright (c) 2006 Eric Wong
|
|
#
|
|
|
|
test_description='git-svn --follow-parent fetching'
|
|
. ./lib-git-svn.sh
|
|
|
|
test_expect_success 'initialize repo' "
|
|
mkdir import &&
|
|
cd import &&
|
|
mkdir -p trunk &&
|
|
echo hello > trunk/readme &&
|
|
svn import -m 'initial' . $svnrepo &&
|
|
cd .. &&
|
|
svn co $svnrepo wc &&
|
|
cd wc &&
|
|
echo world >> trunk/readme &&
|
|
poke trunk/readme &&
|
|
svn commit -m 'another commit' &&
|
|
svn up &&
|
|
svn mv -m 'rename to thunk' trunk thunk &&
|
|
svn up &&
|
|
echo goodbye >> thunk/readme &&
|
|
poke thunk/readme &&
|
|
svn commit -m 'bye now' &&
|
|
cd ..
|
|
"
|
|
|
|
test_expect_success 'init and fetch --follow-parent a moved directory' "
|
|
git-svn init -i thunk $svnrepo/thunk &&
|
|
git-svn fetch --follow-parent -i thunk &&
|
|
git-rev-parse --verify refs/remotes/trunk &&
|
|
test '$?' -eq '0'
|
|
"
|
|
|
|
test_debug 'gitk --all &'
|
|
|
|
test_done
|