Skip to content

Commit 3867906

Browse files
Heiko Voigtgitster
authored andcommitted
cvsimport: extend testcase about patchset order to contain branches
This makes sure that timestamps and ordering on branches is not influenced by a fix for cvsps. The test extension does not deal which patchset correction on branches it only verifes that branches are basically handled as before. Signed-off-by: Heiko Voigt <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 9291ccf commit 3867906

File tree

4 files changed

+103
-11
lines changed

4 files changed

+103
-11
lines changed

t/t9603-cvsimport-patchsets.sh

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -21,13 +21,20 @@ test_expect_failure 'import with criss cross times on revisions' '
2121
2222
git cvsimport -p"-x" -C module-git module &&
2323
cd module-git &&
24-
git log --pretty=format:%s > ../actual &&
25-
echo "" >> ../actual &&
24+
git log --pretty=format:%s > ../actual-master &&
25+
git log A~2..A --pretty="format:%s %ad" -- > ../actual-A &&
26+
echo "" >> ../actual-master &&
27+
echo "" >> ../actual-A &&
2628
cd .. &&
27-
echo "Rev 3
29+
echo "Rev 4
30+
Rev 3
2831
Rev 2
29-
Rev 1" > expect &&
30-
test_cmp actual expect
32+
Rev 1" > expect-master &&
33+
test_cmp actual-master expect-master &&
34+
35+
echo "Rev 5 Branch A Wed Mar 11 19:09:10 2009 +0000
36+
Rev 4 Branch A Wed Mar 11 19:03:52 2009 +0000" > expect-A &&
37+
test_cmp actual-A expect-A
3138
'
3239

3340
test_done

t/t9603/cvsroot/.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
* -whitespace

t/t9603/cvsroot/module/a,v

Lines changed: 36 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,32 @@
11
head 1.2;
22
access;
3-
symbols;
3+
symbols
4+
A:1.2.0.2;
45
locks; strict;
56
comment @# @;
67

78

89
1.2
910
date 2009.02.21.18.11.14; author tester; state Exp;
10-
branches;
11+
branches
12+
1.2.2.1;
1113
next 1.1;
1214

1315
1.1
1416
date 2009.02.21.18.11.43; author tester; state Exp;
1517
branches;
1618
next ;
1719

20+
1.2.2.1
21+
date 2009.03.11.19.03.52; author tester; state Exp;
22+
branches;
23+
next 1.2.2.2;
24+
25+
1.2.2.2
26+
date 2009.03.11.19.09.10; author tester; state Exp;
27+
branches;
28+
next ;
29+
1830

1931
desc
2032
@@
@@ -29,6 +41,28 @@ text
2941
@
3042

3143

44+
1.2.2.1
45+
log
46+
@Rev 4 Branch A
47+
@
48+
text
49+
@d1 1
50+
a1 1
51+
1.2.2.1
52+
@
53+
54+
55+
1.2.2.2
56+
log
57+
@Rev 5 Branch A
58+
@
59+
text
60+
@d1 1
61+
a1 1
62+
1.2.2.2
63+
@
64+
65+
3266
1.1
3367
log
3468
@Rev 1

t/t9603/cvsroot/module/b,v

Lines changed: 54 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,81 @@
1-
head 1.2;
1+
head 1.3;
22
access;
3-
symbols;
3+
symbols
4+
A:1.2.0.2;
45
locks; strict;
56
comment @# @;
67

78

9+
1.3
10+
date 2009.03.11.19.05.08; author tester; state Exp;
11+
branches;
12+
next 1.2;
13+
814
1.2
915
date 2009.02.21.18.11.43; author tester; state Exp;
10-
branches;
16+
branches
17+
1.2.2.1;
1118
next 1.1;
1219

1320
1.1
1421
date 2009.02.21.18.11.14; author tester; state Exp;
1522
branches;
1623
next ;
1724

25+
1.2.2.1
26+
date 2009.03.11.19.03.52; author tester; state Exp;
27+
branches;
28+
next 1.2.2.2;
29+
30+
1.2.2.2
31+
date 2009.03.11.19.09.10; author tester; state Exp;
32+
branches;
33+
next ;
34+
1835

1936
desc
2037
@@
2138

2239

40+
1.3
41+
log
42+
@Rev 4
43+
@
44+
text
45+
@1.3
46+
@
47+
48+
2349
1.2
2450
log
2551
@Rev 3
2652
@
2753
text
28-
@1.2
54+
@d1 1
55+
a1 1
56+
1.2
57+
@
58+
59+
60+
1.2.2.1
61+
log
62+
@Rev 4 Branch A
63+
@
64+
text
65+
@d1 1
66+
a1 1
67+
1.2.2.1
68+
@
69+
70+
71+
1.2.2.2
72+
log
73+
@Rev 5 Branch A
74+
@
75+
text
76+
@d1 1
77+
a1 1
78+
1.2
2979
@
3080

3181

0 commit comments

Comments
 (0)