Skip to content

Commit aa5a7e0

Browse files
committed
Merge branch 'ma/test-cleanup'
Code cleanup. * ma/test-cleanup: t: drop debug `cat` calls t9810: drop debug `cat` call t4117: check for files using `test_path_is_file`
2 parents 58595e7 + 3c29e21 commit aa5a7e0

13 files changed

+5
-17
lines changed

t/t0021-conversion.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -795,7 +795,6 @@ test_expect_success PERL 'missing file in delayed checkout' '
795795
796796
rm -rf repo-cloned &&
797797
test_must_fail git clone repo repo-cloned 2>git-stderr.log &&
798-
cat git-stderr.log &&
799798
grep "error: .missing-delay\.a. was not filtered properly" git-stderr.log
800799
'
801800

t/t1406-submodule-ref-store.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ test_expect_success 'for_each_reflog()' '
7575
'
7676

7777
test_expect_success 'for_each_reflog_ent()' '
78-
$RUN for-each-reflog-ent HEAD >actual && cat actual &&
78+
$RUN for-each-reflog-ent HEAD >actual &&
7979
head -n1 actual | grep first &&
8080
tail -n2 actual | head -n1 | grep master.to.new
8181
'

t/t1450-fsck.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,6 @@ test_expect_success 'email without @ is okay' '
141141
git update-ref refs/heads/bogus "$new" &&
142142
test_when_finished "git update-ref -d refs/heads/bogus" &&
143143
git fsck 2>out &&
144-
cat out &&
145144
! grep "commit $new" out
146145
'
147146

t/t2107-update-index-basic.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ Tests for command-line parsing and basic operation.
99

1010
test_expect_success 'update-index --nonsense fails' '
1111
test_must_fail git update-index --nonsense 2>msg &&
12-
cat msg &&
1312
test -s msg
1413
'
1514

t/t3007-ls-files-recurse-submodules.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,6 @@ test_expect_success '--recurse-submodules and pathspecs setup' '
130130
131131
git ls-files --recurse-submodules >actual &&
132132
test_cmp expect actual &&
133-
cat actual &&
134133
git ls-files --recurse-submodules "*" >actual &&
135134
test_cmp expect actual
136135
'

t/t4117-apply-reject.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ test_expect_success 'apply with --reject should fail but update the file' '
7474
test_must_fail git apply --reject patch.1 &&
7575
test_cmp expected file1 &&
7676
77-
cat file1.rej &&
77+
test_path_is_file file1.rej &&
7878
test_path_is_missing file2.rej
7979
'
8080

@@ -87,7 +87,7 @@ test_expect_success 'apply with --reject should fail but update the file' '
8787
test_path_is_missing file1 &&
8888
test_cmp expected file2 &&
8989
90-
cat file2.rej &&
90+
test_path_is_file file2.rej &&
9191
test_path_is_missing file1.rej
9292
9393
'
@@ -101,7 +101,7 @@ test_expect_success 'the same test with --verbose' '
101101
test_path_is_missing file1 &&
102102
test_cmp expected file2 &&
103103
104-
cat file2.rej &&
104+
test_path_is_file file2.rej &&
105105
test_path_is_missing file1.rej
106106
107107
'

t/t5150-request-pull.sh

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,6 @@ test_expect_success 'pull request after push' '
150150
git request-pull initial origin master:for-upstream >../request
151151
) &&
152152
sed -nf read-request.sed <request >digest &&
153-
cat digest &&
154153
{
155154
read task &&
156155
read repository &&
@@ -179,7 +178,6 @@ test_expect_success 'request asks HEAD to be pulled' '
179178
git request-pull initial "$downstream_url" >../request
180179
) &&
181180
sed -nf read-request.sed <request >digest &&
182-
cat digest &&
183181
{
184182
read task &&
185183
read repository &&

t/t5409-colorize-remote-messages.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,14 +56,13 @@ test_expect_success 'short line' '
5656

5757
test_expect_success 'case-insensitive' '
5858
git --git-dir child/.git -c color.remote=always push -f origin HEAD:refs/heads/case-insensitive 2>output &&
59-
cat output &&
6059
test_decode_color <output >decoded &&
6160
grep "<BOLD;RED>error<RESET>: error" decoded &&
6261
grep "<BOLD;RED>ERROR<RESET>: also highlighted" decoded
6362
'
6463

6564
test_expect_success 'leading space' '
66-
git --git-dir child/.git -c color.remote=always push -f origin HEAD:refs/heads/leading-space 2>output && cat output &&
65+
git --git-dir child/.git -c color.remote=always push -f origin HEAD:refs/heads/leading-space 2>output &&
6766
test_decode_color <output >decoded &&
6867
grep " <BOLD;RED>error<RESET>: leading space" decoded
6968
'

t/t5510-fetch.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -379,7 +379,6 @@ test_expect_success 'fetch from GIT URL with a non-applying branch.<name>.merge
379379
# the strange name is: a\!'b
380380
test_expect_success 'quoting of a strangely named repo' '
381381
test_must_fail git fetch "a\\!'\''b" > result 2>&1 &&
382-
cat result &&
383382
grep "fatal: '\''a\\\\!'\''b'\''" result
384383
'
385384

t/t8003-blame-corner-cases.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,6 @@ test_expect_success 'blame during cherry-pick with file rename conflict' '
173173
git show HEAD@{1}:rodent > rodent &&
174174
git add rodent &&
175175
git blame -f -C -C1 rodent | sed -e "$pick_fc" >current &&
176-
cat current &&
177176
cat >expected <<-\EOF &&
178177
mouse-Initial
179178
mouse-Second

t/t9300-fast-import.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1047,7 +1047,6 @@ test_expect_success 'M: rename root to subdirectory' '
10471047
EOF
10481048
git fast-import <input &&
10491049
git diff-tree -M -r M4^ M4 >actual &&
1050-
cat actual &&
10511050
compare_diff_raw expect actual
10521051
'
10531052

t/t9800-git-p4-basic.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,6 @@ test_expect_success 'exit when p4 fails to produce marshaled output' '
202202
export PATH &&
203203
test_expect_code 1 git p4 clone --dest="$git" //depot >errs 2>&1
204204
) &&
205-
cat errs &&
206205
test_i18ngrep ! Traceback errs
207206
'
208207

t/t9810-git-p4-rcs.sh

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -294,7 +294,6 @@ test_expect_success 'cope with rcs keyword file deletion' '
294294
echo "\$Revision\$" >kwdelfile.c &&
295295
p4 add -t ktext kwdelfile.c &&
296296
p4 submit -d "Add file to be deleted" &&
297-
cat kwdelfile.c &&
298297
grep 1 kwdelfile.c
299298
) &&
300299
git p4 clone --dest="$git" //depot &&

0 commit comments

Comments
 (0)