1#!/bin/sh 2 3# Structure of the test cvs repository 4# 5# Message File:Content Commit Time 6# Rev 1 a: 1.1 2009-02-21 19:11:43 +0100 7# Rev 2 a: 1.2 b: 1.1 2009-02-21 19:11:14 +0100 8# Rev 3 b: 1.2 2009-02-21 19:11:43 +0100 9# 10# As you can see the commit of Rev 3 has the same time as 11# Rev 1 this leads to a broken import because of a cvsps 12# bug. 13 14test_description='git cvsimport testing for correct patchset estimation' 15GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main 16export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME 17 18. ./lib-cvs.sh 19 20setup_cvs_test_repository t9603 21 22test_expect_failure PERL 'import with criss cross times on revisions' ' 23 git cvsimport -p"-x" -C module-git module && 24 ( 25 cd module-git && 26 git log --pretty=format:%s > ../actual-main && 27 git log A~2..A --pretty="format:%s %ad" -- > ../actual-A && 28 echo "" >> ../actual-main && 29 echo "" >> ../actual-A 30 ) && 31 echo "Rev 4 32Rev 3 33Rev 2 34Rev 1" > expect-main && 35 test_cmp expect-main actual-main && 36 37 echo "Rev 5 Branch A Wed Mar 11 19:09:10 2009 +0000 38Rev 4 Branch A Wed Mar 11 19:03:52 2009 +0000" > expect-A && 39 test_cmp expect-A actual-A 40' 41 42test_done 43