X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;ds=sidebyside;f=t%2Ft9300-fast-import.sh;h=328444a3068f5083e3d64e92e88660c724acffdc;hb=b281eea75f0ab68e3c9510323c73b78cd3e62814;hp=5edf56f198dc25b9db47ff363fe49958e5299162;hpb=dceab837557077f70bf082727645925aec443500;p=git.git
diff --git a/t/t9300-fast-import.sh b/t/t9300-fast-import.sh
index 5edf56f19..328444a30 100755
--- a/t/t9300-fast-import.sh
+++ b/t/t9300-fast-import.sh
@@ -3,9 +3,9 @@
# Copyright (c) 2007 Shawn Pearce
#
-test_description='test git-fast-import utility'
+test_description='test git fast-import utility'
. ./test-lib.sh
-. ../diff-lib.sh ;# test-lib chdir's into trash
+. "$TEST_DIRECTORY"/diff-lib.sh ;# test-lib chdir's into trash
file2_data='file2
second line of EOF'
@@ -59,7 +59,7 @@ M 755 :4 file4
INPUT_END
test_expect_success \
'A: create pack from stdin' \
- 'git-fast-import --export-marks=marks.out input <expect <output &&
test_cmp expect output'
@@ -649,7 +649,7 @@ cat >expect <actual &&
compare_diff_raw expect actual'
@@ -670,7 +670,7 @@ cat >expect <actual &&
compare_diff_raw expect actual'
@@ -691,7 +691,7 @@ cat >expect <actual &&
compare_diff_raw expect actual'
@@ -717,7 +717,7 @@ cat >expect <actual &&
compare_diff_raw expect actual'
@@ -751,7 +751,7 @@ cat >expect <actual &&
compare_diff_raw expect actual'
@@ -775,8 +775,8 @@ INPUT_END
test_expect_success \
'N: copy dirty subdirectory' \
- 'git-fast-import input <actual &&
@@ -914,8 +914,160 @@ progress I'm done!
INPUT_END
test_expect_success \
'O: progress outputs as requested by input' \
- 'git-fast-import actual &&
+ 'git fast-import actual &&
grep "progress " expect &&
test_cmp expect actual'
+###
+### series P (gitlinks)
+###
+
+cat >input < $GIT_COMMITTER_DATE
+data 12
+sub_initial
+M 100644 :1 file
+
+blob
+mark :3
+data < $GIT_COMMITTER_DATE
+data 8
+initial
+from refs/heads/master
+M 100644 :3 .gitmodules
+M 160000 :2 sub
+
+blob
+mark :5
+data 20
+test file
+more data
+
+commit refs/heads/sub
+mark :6
+committer $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> $GIT_COMMITTER_DATE
+data 11
+sub_second
+from :2
+M 100644 :5 file
+
+commit refs/heads/subuse1
+mark :7
+committer $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> $GIT_COMMITTER_DATE
+data 7
+second
+from :4
+M 160000 :6 sub
+
+INPUT_END
+
+test_expect_success \
+ 'P: supermodule & submodule mix' \
+ 'git fast-import input < $GIT_COMMITTER_DATE
+data 8
+initial
+from refs/heads/master
+M 100644 :1 .gitmodules
+M 160000 $SUBPREV sub
+
+commit refs/heads/subuse2
+mark :3
+committer $GIT_COMMITTER_NAME <$GIT_COMMITTER_EMAIL> $GIT_COMMITTER_DATE
+data 7
+second
+from :2
+M 160000 $SUBLAST sub
+
+INPUT_END
+
+test_expect_success \
+ 'P: verbatim SHA gitlinks' \
+ 'git branch -D sub &&
+ git gc && git prune &&
+ git fast-import input < $GIT_COMMITTER_DATE
+data <input < $GIT_COMMITTER_DATE
+data <