]>
Commit | Line | Data |
---|---|---|
b2252904 MH |
1 | #!/bin/sh |
2 | ||
3 | # Description of the files in the repository: | |
4 | # | |
5 | # imported-once.txt: | |
6 | # | |
7 | # Imported once. 1.1 and 1.1.1.1 should be identical. | |
8 | # | |
9 | # imported-twice.txt: | |
10 | # | |
11 | # Imported twice. HEAD should reflect the contents of the | |
12 | # second import (i.e., have the same contents as 1.1.1.2). | |
13 | # | |
14 | # imported-modified.txt: | |
15 | # | |
16 | # Imported, then modified on HEAD. HEAD should reflect the | |
17 | # modification. | |
18 | # | |
19 | # imported-modified-imported.txt: | |
20 | # | |
21 | # Imported, then modified on HEAD, then imported again. | |
22 | # | |
23 | # added-imported.txt,v: | |
24 | # | |
25 | # Added with 'cvs add' to create 1.1, then imported with | |
26 | # completely different contents to create 1.1.1.1, therefore the | |
27 | # vendor branch was never the default branch. | |
28 | # | |
29 | # imported-anonymously.txt: | |
30 | # | |
31 | # Like imported-twice.txt, but with a vendor branch whose branch | |
32 | # tag has been removed. | |
33 | ||
34 | test_description='git cvsimport handling of vendor branches' | |
35 | . ./lib-cvs.sh | |
36 | ||
9b777a16 | 37 | setup_cvs_test_repository t9601 |
b2252904 | 38 | |
c2c09e23 | 39 | test_expect_success PERL 'import a module with a vendor branch' ' |
b2252904 MH |
40 | |
41 | git cvsimport -C module-git module | |
42 | ||
43 | ' | |
44 | ||
c2c09e23 | 45 | test_expect_success PERL 'check HEAD out of cvs repository' 'test_cvs_co master' |
b2252904 | 46 | |
c2c09e23 | 47 | test_expect_success PERL 'check master out of git repository' 'test_git_co master' |
b2252904 | 48 | |
c2c09e23 | 49 | test_expect_success PERL 'check a file that was imported once' ' |
b2252904 MH |
50 | |
51 | test_cmp_branch_file master imported-once.txt | |
52 | ||
53 | ' | |
54 | ||
c2c09e23 | 55 | test_expect_failure PERL 'check a file that was imported twice' ' |
b2252904 MH |
56 | |
57 | test_cmp_branch_file master imported-twice.txt | |
58 | ||
59 | ' | |
60 | ||
c2c09e23 | 61 | test_expect_success PERL 'check a file that was imported then modified on HEAD' ' |
b2252904 MH |
62 | |
63 | test_cmp_branch_file master imported-modified.txt | |
64 | ||
65 | ' | |
66 | ||
c2c09e23 | 67 | test_expect_success PERL 'check a file that was imported, modified, then imported again' ' |
b2252904 MH |
68 | |
69 | test_cmp_branch_file master imported-modified-imported.txt | |
70 | ||
71 | ' | |
72 | ||
c2c09e23 | 73 | test_expect_success PERL 'check a file that was added to HEAD then imported' ' |
b2252904 MH |
74 | |
75 | test_cmp_branch_file master added-imported.txt | |
76 | ||
77 | ' | |
78 | ||
c2c09e23 | 79 | test_expect_success PERL 'a vendor branch whose tag has been removed' ' |
b2252904 MH |
80 | |
81 | test_cmp_branch_file master imported-anonymously.txt | |
82 | ||
83 | ' | |
84 | ||
85 | test_done |