t9300, t9301: use "git fast-import/fast-export" without dash
Also use "git hash-object" and "git rev-parse" without dash. Signed-off-by: Nanako Shiraishi <nanako3@lavabit.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Nanako Shiraishi committed
Sep 10, 2008 at 06:25 UTC
eaa2a6fc84bc02c1356353f7364e976e46133e98
2 files changed
+41
-41
t/t9300-fast-import.sh
+40
-40
@@ -3,7 +3,7 @@
3
# Copyright (c) 2007 Shawn Pearce
4
#
5
6
-test_description='test git-fast-import utility'
6
+test_description='test git fast-import utility'
7
. ./test-lib.sh
8
. "$TEST_DIRECTORY"/diff-lib.sh ;# test-lib chdir's into trash
9
@@ -59,7 +59,7 @@ M 755 :4 file4
59
INPUT_END
60
test_expect_success \
61
'A: create pack from stdin' \
62
- 'git-fast-import --export-marks=marks.out <input &&
62
+ 'git fast-import --export-marks=marks.out <input &&
63
git whatchanged master'
64
test_expect_success \
65
'A: verify pack' \
@@ -113,7 +113,7 @@ test_expect_success \
113
114
test_expect_success \
115
'A: verify marks import' \
116
- 'git-fast-import \
116
+ 'git fast-import \
117
--import-marks=marks.out \
118
--export-marks=marks.new \
119
</dev/null &&
@@ -133,7 +133,7 @@ M 755 :2 copy-of-file2
133
INPUT_END
134
test_expect_success \
135
'A: verify marks import does not crash' \
136
- 'git-fast-import --import-marks=marks.out <input &&
136
+ 'git fast-import --import-marks=marks.out <input &&
137
git whatchanged verify--import-marks'
138
test_expect_success \
139
'A: verify pack' \
@@ -166,7 +166,7 @@ M 755 0000000000000000000000000000000000000001 zero1
166
167
INPUT_END
168
test_expect_success 'B: fail on invalid blob sha1' '
169
- test_must_fail git-fast-import <input
169
+ test_must_fail git fast-import <input
170
'
171
rm -f .git/objects/pack_* .git/objects/index_*
172
@@ -181,7 +181,7 @@ from refs/heads/master
181
182
INPUT_END
183
test_expect_success 'B: fail on invalid branch name ".badbranchname"' '
184
- test_must_fail git-fast-import <input
184
+ test_must_fail git fast-import <input
185
'
186
rm -f .git/objects/pack_* .git/objects/index_*
187
@@ -196,7 +196,7 @@ from refs/heads/master
196
197
INPUT_END
198
test_expect_success 'B: fail on invalid branch name "bad[branch]name"' '
199
- test_must_fail git-fast-import <input
199
+ test_must_fail git fast-import <input
200
'
201
rm -f .git/objects/pack_* .git/objects/index_*
202
@@ -212,7 +212,7 @@ from refs/heads/master
212
INPUT_END
213
test_expect_success \
214
'B: accept branch name "TEMP_TAG"' \
215
- 'git-fast-import <input &&
215
+ 'git fast-import <input &&
216
test -f .git/TEMP_TAG &&
217
test `git rev-parse master` = `git rev-parse TEMP_TAG^`'
218
rm -f .git/TEMP_TAG
@@ -221,7 +221,7 @@ rm -f .git/TEMP_TAG
221
### series C
222
###
223
224
-newf=`echo hi newf | git-hash-object -w --stdin`
224
+newf=`echo hi newf | git hash-object -w --stdin`
225
oldf=`git rev-parse --verify master:file2`
226
test_tick
227
cat >input <<INPUT_END
@@ -239,7 +239,7 @@ D file3
239
INPUT_END
240
test_expect_success \
241
'C: incremental import create pack from stdin' \
242
- 'git-fast-import <input &&
242
+ 'git fast-import <input &&
243
git whatchanged branch'
244
test_expect_success \
245
'C: verify pack' \
@@ -297,7 +297,7 @@ EOF
297
INPUT_END
298
test_expect_success \
299
'D: inline data in commit' \
300
- 'git-fast-import <input &&
300
+ 'git fast-import <input &&
301
git whatchanged branch'
302
test_expect_success \
303
'D: verify pack' \
@@ -340,11 +340,11 @@ from refs/heads/branch^0
340
341
INPUT_END
342
test_expect_success 'E: rfc2822 date, --date-format=raw' '
343
- test_must_fail git-fast-import --date-format=raw <input
343
+ test_must_fail git fast-import --date-format=raw <input
344
'
345
test_expect_success \
346
'E: rfc2822 date, --date-format=rfc2822' \
347
- 'git-fast-import --date-format=rfc2822 <input'
347
+ 'git fast-import --date-format=rfc2822 <input'
348
test_expect_success \
349
'E: verify pack' \
350
'for p in .git/objects/pack/*.pack;do git verify-pack $p||exit;done'
@@ -381,7 +381,7 @@ from refs/heads/branch
381
INPUT_END
382
test_expect_success \
383
'F: non-fast-forward update skips' \
384
- 'if git-fast-import <input
384
+ 'if git fast-import <input
385
then
386
echo BAD gfi did not fail
387
return 1
@@ -431,7 +431,7 @@ from refs/heads/branch~1
431
INPUT_END
432
test_expect_success \
433
'G: non-fast-forward update forced' \
434
- 'git-fast-import --force <input'
434
+ 'git fast-import --force <input'
435
test_expect_success \
436
'G: verify pack' \
437
'for p in .git/objects/pack/*.pack;do git verify-pack $p||exit;done'
@@ -467,7 +467,7 @@ EOF
467
INPUT_END
468
test_expect_success \
469
'H: deletall, add 1' \
470
- 'git-fast-import <input &&
470
+ 'git fast-import <input &&
471
git whatchanged H'
472
test_expect_success \
473
'H: verify pack' \
@@ -507,7 +507,7 @@ from refs/heads/branch
507
INPUT_END
508
test_expect_success \
509
'I: export-pack-edges' \
510
- 'git-fast-import --export-pack-edges=edges.list <input'
510
+ 'git fast-import --export-pack-edges=edges.list <input'
511
512
cat >expect <<EOF
513
.git/objects/pack/pack-.pack: `git rev-parse --verify export-boundary`
@@ -541,7 +541,7 @@ COMMIT
541
INPUT_END
542
test_expect_success \
543
'J: reset existing branch creates empty commit' \
544
- 'git-fast-import <input'
544
+ 'git fast-import <input'
545
test_expect_success \
546
'J: branch has 1 commit, empty tree' \
547
'test 1 = `git rev-list J | wc -l` &&
@@ -571,7 +571,7 @@ from refs/heads/branch^1
571
INPUT_END
572
test_expect_success \
573
'K: reinit branch with from' \
574
- 'git-fast-import <input'
574
+ 'git fast-import <input'
575
test_expect_success \
576
'K: verify K^1 = branch^1' \
577
'test `git rev-parse --verify branch^1` \
@@ -623,7 +623,7 @@ EXPECT_END
623
624
test_expect_success \
625
'L: verify internal tree sorting' \
626
- 'git-fast-import <input &&
626
+ 'git fast-import <input &&
627
git diff-tree --abbrev --raw L^ L >output &&
628
test_cmp expect output'
629
@@ -649,7 +649,7 @@ cat >expect <<EOF
649
EOF
650
test_expect_success \
651
'M: rename file in same subdirectory' \
652
- 'git-fast-import <input &&
652
+ 'git fast-import <input &&
653
git diff-tree -M -r M1^ M1 >actual &&
654
compare_diff_raw expect actual'
655
@@ -670,7 +670,7 @@ cat >expect <<EOF
670
EOF
671
test_expect_success \
672
'M: rename file to new subdirectory' \
673
- 'git-fast-import <input &&
673
+ 'git fast-import <input &&
674
git diff-tree -M -r M2^ M2 >actual &&
675
compare_diff_raw expect actual'
676
@@ -691,7 +691,7 @@ cat >expect <<EOF
691
EOF
692
test_expect_success \
693
'M: rename subdirectory to new subdirectory' \
694
- 'git-fast-import <input &&
694
+ 'git fast-import <input &&
695
git diff-tree -M -r M3^ M3 >actual &&
696
compare_diff_raw expect actual'
697
@@ -717,7 +717,7 @@ cat >expect <<EOF
717
EOF
718
test_expect_success \
719
'N: copy file in same subdirectory' \
720
- 'git-fast-import <input &&
720
+ 'git fast-import <input &&
721
git diff-tree -C --find-copies-harder -r N1^ N1 >actual &&
722
compare_diff_raw expect actual'
723
@@ -751,7 +751,7 @@ cat >expect <<EOF
751
EOF
752
test_expect_success \
753
'N: copy then modify subdirectory' \
754
- 'git-fast-import <input &&
754
+ 'git fast-import <input &&
755
git diff-tree -C --find-copies-harder -r N2^^ N2 >actual &&
756
compare_diff_raw expect actual'
757
@@ -775,8 +775,8 @@ INPUT_END
775
776
test_expect_success \
777
'N: copy dirty subdirectory' \
778
- 'git-fast-import <input &&
779
- test `git-rev-parse N2^{tree}` = `git-rev-parse N3^{tree}`'
778
+ 'git fast-import <input &&
779
+ test `git rev-parse N2^{tree}` = `git rev-parse N3^{tree}`'
780
781
###
782
### series O
@@ -815,8 +815,8 @@ INPUT_END
815
816
test_expect_success \
817
'O: comments are all skipped' \
818
- 'git-fast-import <input &&
819
- test `git-rev-parse N3` = `git-rev-parse O1`'
818
+ 'git fast-import <input &&
819
+ test `git rev-parse N3` = `git rev-parse O1`'
820
821
cat >input <<INPUT_END
822
commit refs/heads/O2
@@ -836,8 +836,8 @@ INPUT_END
836
837
test_expect_success \
838
'O: blank lines not necessary after data commands' \
839
- 'git-fast-import <input &&
840
- test `git-rev-parse N3` = `git-rev-parse O2`'
839
+ 'git fast-import <input &&
840
+ test `git rev-parse N3` = `git rev-parse O2`'
841
842
test_expect_success \
843
'O: repack before next test' \
@@ -881,7 +881,7 @@ commits
881
INPUT_END
882
test_expect_success \
883
'O: blank lines not necessary after other commands' \
884
- 'git-fast-import <input &&
884
+ 'git fast-import <input &&
885
test 8 = `find .git/objects/pack -type f | wc -l` &&
886
test `git rev-parse refs/tags/O3-2nd` = `git rev-parse O3^` &&
887
git log --reverse --pretty=oneline O3 | sed s/^.*z// >actual &&
@@ -914,7 +914,7 @@ progress I'm done!
914
INPUT_END
915
test_expect_success \
916
'O: progress outputs as requested by input' \
917
- 'git-fast-import <input >actual &&
917
+ 'git fast-import <input >actual &&
918
grep "progress " <input >expect &&
919
test_cmp expect actual'
920
@@ -979,7 +979,7 @@ INPUT_END
979
980
test_expect_success \
981
'P: supermodule & submodule mix' \
982
- 'git-fast-import <input &&
982
+ 'git fast-import <input &&
983
git checkout subuse1 &&
984
rm -rf sub && mkdir sub && cd sub &&
985
git init &&
@@ -989,8 +989,8 @@ test_expect_success \
989
git submodule init &&
990
git submodule update'
991
992
-SUBLAST=$(git-rev-parse --verify sub)
993
-SUBPREV=$(git-rev-parse --verify sub^)
992
+SUBLAST=$(git rev-parse --verify sub)
993
+SUBPREV=$(git rev-parse --verify sub^)
994
995
cat >input <<INPUT_END
996
blob
@@ -1024,8 +1024,8 @@ test_expect_success \
1024
'P: verbatim SHA gitlinks' \
1025
'git branch -D sub &&
1026
git gc && git prune &&
1027
- git-fast-import <input &&
1028
- test $(git-rev-parse --verify subuse2) = $(git-rev-parse --verify subuse1)'
1027
+ git fast-import <input &&
1028
+ test $(git rev-parse --verify subuse2) = $(git rev-parse --verify subuse1)'
1029
1030
test_tick
1031
cat >input <<INPUT_END
@@ -1045,7 +1045,7 @@ DATA
1045
INPUT_END
1046
1047
test_expect_success 'P: fail on inline gitlink' '
1048
- test_must_fail git-fast-import <input'
1048
+ test_must_fail git fast-import <input'
1049
1050
test_tick
1051
cat >input <<INPUT_END
@@ -1068,6 +1068,6 @@ M 160000 :1 sub
1068
INPUT_END
1069
1070
test_expect_success 'P: fail on blob mark in gitlink' '
1071
- test_must_fail git-fast-import <input'
1071
+ test_must_fail git fast-import <input'
1072
1073
test_done
t/t9301-fast-export.sh
+1
-1
@@ -3,7 +3,7 @@
3
# Copyright (c) 2007 Johannes E. Schindelin
4
#
5
6
-test_description='git-fast-export'
6
+test_description='git fast-export'
7
. ./test-lib.sh
8
9
test_expect_success 'setup' '