@matheusbsbs / matheus-bagliano / commits / 47a528ad24
Fork 0

tests: use "git xyzzy" form (t7200 - t9001)

Converts tests between t7201-t9001. Signed-off-by: Nanako Shiraishi <nanako3@lavabit.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Nanako Shiraishi committed Sep 3, 2008 at 17:59 UTC 47a528ad24185133867ebb5bb7692db2cb8bef39
18 files changed +99 -99
t/t7201-co.sh
+1 -1
@@ -3,7 +3,7 @@
3 # Copyright (c) 2006 Junio C Hamano
4 #
5
6 -test_description='git-checkout tests.
6 +test_description='git checkout tests.
7
8 Creates master, forks renamer and side branches from it.
9 Test switching across them.
t/t7300-clean.sh
+36 -36
@@ -3,7 +3,7 @@
3 # Copyright (c) 2007 Michael Spang
4 #
5
6 -test_description='git-clean basic tests'
6 +test_description='git clean basic tests'
7
8 . ./test-lib.sh
9
@@ -16,17 +16,17 @@ test_expect_success 'setup' '
16 echo build >.gitignore &&
17 echo \*.o >>.gitignore &&
18 git add . &&
19 - git-commit -m setup &&
19 + git commit -m setup &&
20 touch src/part2.c README &&
21 git add .
22
23 '
24
25 -test_expect_success 'git-clean' '
25 +test_expect_success 'git clean' '
26
27 mkdir -p build docs &&
28 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
29 - git-clean &&
29 + git clean &&
30 test -f Makefile &&
31 test -f README &&
32 test -f src/part1.c &&
@@ -39,11 +39,11 @@ test_expect_success 'git-clean' '
39
40 '
41
42 -test_expect_success 'git-clean src/' '
42 +test_expect_success 'git clean src/' '
43
44 mkdir -p build docs &&
45 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
46 - git-clean src/ &&
46 + git clean src/ &&
47 test -f Makefile &&
48 test -f README &&
49 test -f src/part1.c &&
@@ -56,11 +56,11 @@ test_expect_success 'git-clean src/' '
56
57 '
58
59 -test_expect_success 'git-clean src/ src/' '
59 +test_expect_success 'git clean src/ src/' '
60
61 mkdir -p build docs &&
62 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
63 - git-clean src/ src/ &&
63 + git clean src/ src/ &&
64 test -f Makefile &&
65 test -f README &&
66 test -f src/part1.c &&
@@ -73,11 +73,11 @@ test_expect_success 'git-clean src/ src/' '
73
74 '
75
76 -test_expect_success 'git-clean with prefix' '
76 +test_expect_success 'git clean with prefix' '
77
78 mkdir -p build docs src/test &&
79 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so src/test/1.c &&
80 - (cd src/ && git-clean) &&
80 + (cd src/ && git clean) &&
81 test -f Makefile &&
82 test -f README &&
83 test -f src/part1.c &&
@@ -91,7 +91,7 @@ test_expect_success 'git-clean with prefix' '
91
92 '
93
94 -test_expect_success 'git-clean with relative prefix' '
94 +test_expect_success 'git clean with relative prefix' '
95
96 mkdir -p build docs &&
97 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
@@ -106,7 +106,7 @@ test_expect_success 'git-clean with relative prefix' '
106 }
107 '
108
109 -test_expect_success 'git-clean with absolute path' '
109 +test_expect_success 'git clean with absolute path' '
110
111 mkdir -p build docs &&
112 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
@@ -121,7 +121,7 @@ test_expect_success 'git-clean with absolute path' '
121 }
122 '
123
124 -test_expect_success 'git-clean with out of work tree relative path' '
124 +test_expect_success 'git clean with out of work tree relative path' '
125
126 mkdir -p build docs &&
127 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
@@ -131,7 +131,7 @@ test_expect_success 'git-clean with out of work tree relative path' '
131 )
132 '
133
134 -test_expect_success 'git-clean with out of work tree absolute path' '
134 +test_expect_success 'git clean with out of work tree absolute path' '
135
136 mkdir -p build docs &&
137 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
@@ -142,11 +142,11 @@ test_expect_success 'git-clean with out of work tree absolute path' '
142 )
143 '
144
145 -test_expect_success 'git-clean -d with prefix and path' '
145 +test_expect_success 'git clean -d with prefix and path' '
146
147 mkdir -p build docs src/feature &&
148 touch a.out src/part3.c src/feature/file.c docs/manual.txt obj.o build/lib.so &&
149 - (cd src/ && git-clean -d feature/) &&
149 + (cd src/ && git clean -d feature/) &&
150 test -f Makefile &&
151 test -f README &&
152 test -f src/part1.c &&
@@ -160,12 +160,12 @@ test_expect_success 'git-clean -d with prefix and path' '
160
161 '
162
163 -test_expect_success 'git-clean symbolic link' '
163 +test_expect_success 'git clean symbolic link' '
164
165 mkdir -p build docs &&
166 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
167 ln -s docs/manual.txt src/part4.c
168 - git-clean &&
168 + git clean &&
169 test -f Makefile &&
170 test -f README &&
171 test -f src/part1.c &&
@@ -179,10 +179,10 @@ test_expect_success 'git-clean symbolic link' '
179
180 '
181
182 -test_expect_success 'git-clean with wildcard' '
182 +test_expect_success 'git clean with wildcard' '
183
184 touch a.clean b.clean other.c &&
185 - git-clean "*.clean" &&
185 + git clean "*.clean" &&
186 test -f Makefile &&
187 test -f README &&
188 test -f src/part1.c &&
@@ -193,11 +193,11 @@ test_expect_success 'git-clean with wildcard' '
193
194 '
195
196 -test_expect_success 'git-clean -n' '
196 +test_expect_success 'git clean -n' '
197
198 mkdir -p build docs &&
199 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
200 - git-clean -n &&
200 + git clean -n &&
201 test -f Makefile &&
202 test -f README &&
203 test -f src/part1.c &&
@@ -210,11 +210,11 @@ test_expect_success 'git-clean -n' '
210
211 '
212
213 -test_expect_success 'git-clean -d' '
213 +test_expect_success 'git clean -d' '
214
215 mkdir -p build docs &&
216 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
217 - git-clean -d &&
217 + git clean -d &&
218 test -f Makefile &&
219 test -f README &&
220 test -f src/part1.c &&
@@ -227,11 +227,11 @@ test_expect_success 'git-clean -d' '
227
228 '
229
230 -test_expect_success 'git-clean -d src/ examples/' '
230 +test_expect_success 'git clean -d src/ examples/' '
231
232 mkdir -p build docs examples &&
233 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so examples/1.c &&
234 - git-clean -d src/ examples/ &&
234 + git clean -d src/ examples/ &&
235 test -f Makefile &&
236 test -f README &&
237 test -f src/part1.c &&
@@ -245,11 +245,11 @@ test_expect_success 'git-clean -d src/ examples/' '
245
246 '
247
248 -test_expect_success 'git-clean -x' '
248 +test_expect_success 'git clean -x' '
249
250 mkdir -p build docs &&
251 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
252 - git-clean -x &&
252 + git clean -x &&
253 test -f Makefile &&
254 test -f README &&
255 test -f src/part1.c &&
@@ -262,11 +262,11 @@ test_expect_success 'git-clean -x' '
262
263 '
264
265 -test_expect_success 'git-clean -d -x' '
265 +test_expect_success 'git clean -d -x' '
266
267 mkdir -p build docs &&
268 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
269 - git-clean -d -x &&
269 + git clean -d -x &&
270 test -f Makefile &&
271 test -f README &&
272 test -f src/part1.c &&
@@ -279,11 +279,11 @@ test_expect_success 'git-clean -d -x' '
279
280 '
281
282 -test_expect_success 'git-clean -X' '
282 +test_expect_success 'git clean -X' '
283
284 mkdir -p build docs &&
285 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
286 - git-clean -X &&
286 + git clean -X &&
287 test -f Makefile &&
288 test -f README &&
289 test -f src/part1.c &&
@@ -296,11 +296,11 @@ test_expect_success 'git-clean -X' '
296
297 '
298
299 -test_expect_success 'git-clean -d -X' '
299 +test_expect_success 'git clean -d -X' '
300
301 mkdir -p build docs &&
302 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
303 - git-clean -d -X &&
303 + git clean -d -X &&
304 test -f Makefile &&
305 test -f README &&
306 test -f src/part1.c &&
@@ -331,7 +331,7 @@ test_expect_success 'clean.requireForce and -n' '
331
332 mkdir -p build docs &&
333 touch a.out src/part3.c docs/manual.txt obj.o build/lib.so &&
334 - git-clean -n &&
334 + git clean -n &&
335 test -f Makefile &&
336 test -f README &&
337 test -f src/part1.c &&
@@ -346,7 +346,7 @@ test_expect_success 'clean.requireForce and -n' '
346
347 test_expect_success 'clean.requireForce and -f' '
348
349 - git-clean -f &&
349 + git clean -f &&
350 test -f README &&
351 test -f src/part1.c &&
352 test -f src/part2.c &&
t/t7400-submodule-basic.sh
+24 -24
@@ -6,7 +6,7 @@
6 test_description='Basic porcelain support for submodules
7
8 This test tries to verify basic sanity of the init, update and status
9 -subcommands of git-submodule.
9 +subcommands of git submodule.
10 '
11
12 . ./test-lib.sh
@@ -22,16 +22,16 @@ subcommands of git-submodule.
22 #
23 test_expect_success 'Prepare submodule testing' '
24 : > t &&
25 - git-add t &&
26 - git-commit -m "initial commit" &&
25 + git add t &&
26 + git commit -m "initial commit" &&
27 git branch initial HEAD &&
28 mkdir init &&
29 cd init &&
30 git init &&
31 echo a >a &&
32 git add a &&
33 - git-commit -m "submodule commit 1" &&
34 - git-tag -a -m "rev-1" rev-1 &&
33 + git commit -m "submodule commit 1" &&
34 + git tag -a -m "rev-1" rev-1 &&
35 rev1=$(git rev-parse HEAD) &&
36 if test -z "$rev1"
37 then
@@ -42,13 +42,13 @@ test_expect_success 'Prepare submodule testing' '
42 echo a >a &&
43 echo z >z &&
44 git add a init z &&
45 - git-commit -m "super commit 1" &&
45 + git commit -m "super commit 1" &&
46 mv init .subrepo &&
47 GIT_CONFIG=.gitmodules git config submodule.example.url git://example.com/init.git
48 '
49
50 test_expect_success 'status should fail for unmapped paths' '
51 - if git-submodule status
51 + if git submodule status
52 then
53 echo "[OOPS] submodule status succeeded"
54 false
@@ -60,16 +60,16 @@ test_expect_success 'status should fail for unmapped paths' '
60 '
61
62 test_expect_success 'status should only print one line' '
63 - lines=$(git-submodule status | wc -l) &&
63 + lines=$(git submodule status | wc -l) &&
64 test $lines = 1
65 '
66
67 test_expect_success 'status should initially be "missing"' '
68 - git-submodule status | grep "^-$rev1"
68 + git submodule status | grep "^-$rev1"
69 '
70
71 test_expect_success 'init should register submodule url in .git/config' '
72 - git-submodule init &&
72 + git submodule init &&
73 url=$(git config submodule.example.url) &&
74 if test "$url" != "git://example.com/init.git"
75 then
@@ -84,7 +84,7 @@ test_expect_success 'init should register submodule url in .git/config' '
84
85 test_expect_success 'update should fail when path is used by a file' '
86 echo "hello" >init &&
87 - if git-submodule update
87 + if git submodule update
88 then
89 echo "[OOPS] update should have failed"
90 false
@@ -100,7 +100,7 @@ test_expect_success 'update should fail when path is used by a file' '
100 test_expect_success 'update should fail when path is used by a nonempty directory' '
101 mkdir init &&
102 echo "hello" >init/a &&
103 - if git-submodule update
103 + if git submodule update
104 then
105 echo "[OOPS] update should have failed"
106 false
@@ -116,7 +116,7 @@ test_expect_success 'update should fail when path is used by a nonempty director
116 test_expect_success 'update should work when path is an empty dir' '
117 rm -rf init &&
118 mkdir init &&
119 - git-submodule update &&
119 + git submodule update &&
120 head=$(cd init && git rev-parse HEAD) &&
121 if test -z "$head"
122 then
@@ -130,14 +130,14 @@ test_expect_success 'update should work when path is an empty dir' '
130 '
131
132 test_expect_success 'status should be "up-to-date" after update' '
133 - git-submodule status | grep "^ $rev1"
133 + git submodule status | grep "^ $rev1"
134 '
135
136 test_expect_success 'status should be "modified" after submodule commit' '
137 cd init &&
138 echo b >b &&
139 git add b &&
140 - git-commit -m "submodule commit 2" &&
140 + git commit -m "submodule commit 2" &&
141 rev2=$(git rev-parse HEAD) &&
142 cd .. &&
143 if test -z "$rev2"
@@ -145,19 +145,19 @@ test_expect_success 'status should be "modified" after submodule commit' '
145 echo "[OOPS] submodule git rev-parse returned nothing"
146 false
147 fi &&
148 - git-submodule status | grep "^+$rev2"
148 + git submodule status | grep "^+$rev2"
149 '
150
151 test_expect_success 'the --cached sha1 should be rev1' '
152 - git-submodule --cached status | grep "^+$rev1"
152 + git submodule --cached status | grep "^+$rev1"
153 '
154
155 test_expect_success 'git diff should report the SHA1 of the new submodule commit' '
156 - git-diff | grep "^+Subproject commit $rev2"
156 + git diff | grep "^+Subproject commit $rev2"
157 '
158
159 test_expect_success 'update should checkout rev1' '
160 - git-submodule update init &&
160 + git submodule update init &&
161 head=$(cd init && git rev-parse HEAD) &&
162 if test -z "$head"
163 then
@@ -171,12 +171,12 @@ test_expect_success 'update should checkout rev1' '
171 '
172
173 test_expect_success 'status should be "up-to-date" after update' '
174 - git-submodule status | grep "^ $rev1"
174 + git submodule status | grep "^ $rev1"
175 '
176
177 test_expect_success 'checkout superproject with subproject already present' '
178 - git-checkout initial &&
179 - git-checkout master
178 + git checkout initial &&
179 + git checkout master
180 '
181
182 test_expect_success 'apply submodule diff' '
@@ -188,8 +188,8 @@ test_expect_success 'apply submodule diff' '
188 git commit -m "change subproject"
189 ) &&
190 git update-index --add init &&
191 - git-commit -m "change init" &&
192 - git-format-patch -1 --stdout >P.diff &&
191 + git commit -m "change init" &&
192 + git format-patch -1 --stdout >P.diff &&
193 git checkout second &&
194 git apply --index P.diff &&
195 D=$(git diff --cached master) &&
t/t7401-submodule-summary.sh
+1 -1
@@ -5,7 +5,7 @@
5
6 test_description='Summary support for submodules
7
8 -This test tries to verify the sanity of summary subcommand of git-submodule.
8 +This test tries to verify the sanity of summary subcommand of git submodule.
9 '
10
11 . ./test-lib.sh
t/t7500-commit.sh
+1 -1
@@ -3,7 +3,7 @@
3 # Copyright (c) 2007 Steven Grimm
4 #
5
6 -test_description='git-commit
6 +test_description='git commit
7
8 Tests for selected commit options.'
9
t/t7501-commit.sh
+24 -24
@@ -6,7 +6,7 @@
6 # FIXME: Test the various index usages, -i and -o, test reflog,
7 # signoff
8
9 -test_description='git-commit'
9 +test_description='git commit'
10 . ./test-lib.sh
11
12 test_tick
@@ -14,52 +14,52 @@ test_tick
14 test_expect_success \
15 "initial status" \
16 "echo 'bongo bongo' >file &&
17 - git-add file && \
18 - git-status | grep 'Initial commit'"
17 + git add file && \
18 + git status | grep 'Initial commit'"
19
20 test_expect_success \
21 "fail initial amend" \
22 - "test_must_fail git-commit --amend"
22 + "test_must_fail git commit --amend"
23
24 test_expect_success \
25 "initial commit" \
26 - "git-commit -m initial"
26 + "git commit -m initial"
27
28 test_expect_success \
29 "invalid options 1" \
30 - "test_must_fail git-commit -m foo -m bar -F file"
30 + "test_must_fail git commit -m foo -m bar -F file"
31
32 test_expect_success \
33 "invalid options 2" \
34 - "test_must_fail git-commit -C HEAD -m illegal"
34 + "test_must_fail git commit -C HEAD -m illegal"
35
36 test_expect_success \
37 "using paths with -a" \
38 "echo King of the bongo >file &&
39 - test_must_fail git-commit -m foo -a file"
39 + test_must_fail git commit -m foo -a file"
40
41 test_expect_success \
42 "using paths with --interactive" \
43 "echo bong-o-bong >file &&
44 - ! (echo 7 | git-commit -m foo --interactive file)"
44 + ! (echo 7 | git commit -m foo --interactive file)"
45
46 test_expect_success \
47 "using invalid commit with -C" \
48 - "test_must_fail git-commit -C bogus"
48 + "test_must_fail git commit -C bogus"
49
50 test_expect_success \
51 "testing nothing to commit" \
52 - "test_must_fail git-commit -m initial"
52 + "test_must_fail git commit -m initial"
53
54 test_expect_success \
55 "next commit" \
56 "echo 'bongo bongo bongo' >file \
57 - git-commit -m next -a"
57 + git commit -m next -a"
58
59 test_expect_success \
60 "commit message from non-existing file" \
61 "echo 'more bongo: bongo bongo bongo bongo' >file && \
62 - test_must_fail git-commit -F gah -a"
62 + test_must_fail git commit -F gah -a"
63
64 # Empty except stray tabs and spaces on a few lines.
65 sed -e 's/@$//' >msg <<EOF
@@ -70,12 +70,12 @@ Signed-off-by: hula
70 EOF
71 test_expect_success \
72 "empty commit message" \
73 - "test_must_fail git-commit -F msg -a"
73 + "test_must_fail git commit -F msg -a"
74
75 test_expect_success \
76 "commit message from file" \
77 "echo 'this is the commit message, coming from a file' >msg && \
78 - git-commit -F msg -a"
78 + git commit -F msg -a"
79
80 cat >editor <<\EOF
81 #!/bin/sh
@@ -86,16 +86,16 @@ chmod 755 editor
86
87 test_expect_success \
88 "amend commit" \
89 - "VISUAL=./editor git-commit --amend"
89 + "VISUAL=./editor git commit --amend"
90
91 test_expect_success \
92 "passing -m and -F" \
93 "echo 'enough with the bongos' >file && \
94 - test_must_fail git-commit -F msg -m amending ."
94 + test_must_fail git commit -F msg -m amending ."
95
96 test_expect_success \
97 "using message from other commit" \
98 - "git-commit -C HEAD^ ."
98 + "git commit -C HEAD^ ."
99
100 cat >editor <<\EOF
101 #!/bin/sh
@@ -107,25 +107,25 @@ chmod 755 editor
107 test_expect_success \
108 "editing message from other commit" \
109 "echo 'hula hula' >file && \
110 - VISUAL=./editor git-commit -c HEAD^ -a"
110 + VISUAL=./editor git commit -c HEAD^ -a"
111
112 test_expect_success \
113 "message from stdin" \
114 "echo 'silly new contents' >file && \
115 - echo commit message from stdin | git-commit -F - -a"
115 + echo commit message from stdin | git commit -F - -a"
116
117 test_expect_success \
118 "overriding author from command line" \
119 "echo 'gak' >file && \
120 - git-commit -m 'author' --author 'Rubber Duck <rduck@convoy.org>' -a"
120 + git commit -m 'author' --author 'Rubber Duck <rduck@convoy.org>' -a"
121
122 test_expect_success \
123 "interactive add" \
124 - "echo 7 | git-commit --interactive | grep 'What now'"
124 + "echo 7 | git commit --interactive | grep 'What now'"
125
126 test_expect_success \
127 "showing committed revisions" \
128 - "git-rev-list HEAD >current"
128 + "git rev-list HEAD >current"
129
130 # We could just check the head sha1, but checking each commit makes it
131 # easier to isolate bugs.
@@ -140,7 +140,7 @@ d381ac431806e53f3dd7ac2f1ae0534f36d738b9
140 EOF
141
142 test_expect_success \
143 - 'validate git-rev-list output.' \
143 + 'validate git rev-list output.' \
144 'diff current expected'
145
146 test_expect_success 'partial commit that involves removal (1)' '
t/t7502-status.sh
+1 -1
@@ -3,7 +3,7 @@
3 # Copyright (c) 2007 Johannes E. Schindelin
4 #
5
6 -test_description='git-status'
6 +test_description='git status'
7
8 . ./test-lib.sh
9
t/t7505-prepare-commit-msg-hook.sh
+1 -1
@@ -32,7 +32,7 @@ echo "#!$SHELL_PATH" > "$HOOK"
32 cat >> "$HOOK" <<'EOF'
33
34 if test "$2" = commit; then
35 - source=$(git-rev-parse "$3")
35 + source=$(git rev-parse "$3")
36 else
37 source=${2-default}
38 fi
t/t7506-status-submodule.sh
+1 -1
@@ -1,6 +1,6 @@
1 #!/bin/sh
2
3 -test_description='git-status for submodule'
3 +test_description='git status for submodule'
4
5 . ./test-lib.sh
6
t/t7600-merge.sh
+1 -1
@@ -3,7 +3,7 @@
3 # Copyright (c) 2007 Lars Hjemli
4 #
5
6 -test_description='git-merge
6 +test_description='git merge
7
8 Testing basic merge operations/option parsing.'
9
t/t7601-merge-pull-config.sh
+1 -1
@@ -1,6 +1,6 @@
1 #!/bin/sh
2
3 -test_description='git-merge
3 +test_description='git merge
4
5 Testing pull.* configuration parsing.'
6
t/t7602-merge-octopus-many.sh
+1 -1
@@ -1,6 +1,6 @@
1 #!/bin/sh
2
3 -test_description='git-merge
3 +test_description='git merge
4
5 Testing octopus merge with more than 25 refs.'
6
t/t7603-merge-reduce-heads.sh
+1 -1
@@ -1,6 +1,6 @@
1 #!/bin/sh
2
3 -test_description='git-merge
3 +test_description='git merge
4
5 Testing octopus merge when reducing parents to independent branches.'
6
t/t7604-merge-custom-message.sh
+1 -1
@@ -1,6 +1,6 @@
1 #!/bin/sh
2
3 -test_description='git-merge
3 +test_description='git merge
4
5 Testing merge when using a custom message for the merge commit.'
6
t/t7605-merge-resolve.sh
+1 -1
@@ -1,6 +1,6 @@
1 #!/bin/sh
2
3 -test_description='git-merge
3 +test_description='git merge
4
5 Testing the resolve strategy.'
6
t/t7610-mergetool.sh
+1 -1
@@ -3,7 +3,7 @@
3 # Copyright (c) 2008 Charles Bailey
4 #
5
6 -test_description='git-mergetool
6 +test_description='git mergetool
7
8 Testing basic merge tool invocation'
9
t/t7701-repack-unpack-unreachable.sh
+1 -1
@@ -1,6 +1,6 @@
1 #!/bin/sh
2
3 -test_description='git-repack works correctly'
3 +test_description='git repack works correctly'
4
5 . ./test-lib.sh
6
t/t9001-send-email.sh
+1 -1
@@ -1,6 +1,6 @@
1 #!/bin/sh
2
3 -test_description='git-send-email'
3 +test_description='git send-email'
4 . ./test-lib.sh
5
6 PROG='git send-email'