Skip to content

Commit 7f3cc51

Browse files
committed
Merge branch 'ar/test-cleanup-unused-file-creation-part2'
Test cleanup. * ar/test-cleanup-unused-file-creation-part2: t2019: don't create unused files t1502: don't create unused files t1450: don't create unused files t1300: don't create unused files t1300: fix config file syntax error descriptions t0300: don't create unused file
2 parents b6e9521 + a5855fd commit 7f3cc51

File tree

5 files changed

+12
-15
lines changed

5 files changed

+12
-15
lines changed

t/t0300-credentials.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -808,7 +808,7 @@ test_expect_success 'credential config with partial URLs' '
808808
809809
git -c credential.$partial.helper=yep \
810810
-c credential.with%0anewline.username=uh-oh \
811-
credential fill <stdin >stdout 2>stderr &&
811+
credential fill <stdin 2>stderr &&
812812
test_i18ngrep "skipping credential lookup for key" stderr
813813
'
814814

t/t1300-config.sh

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1601,11 +1601,11 @@ test_expect_success 'git config --edit respects core.editor' '
16011601
# malformed configuration files
16021602
test_expect_success 'barf on syntax error' '
16031603
cat >.git/config <<-\EOF &&
1604-
# broken section line
1604+
# broken key=value
16051605
[section]
16061606
key garbage
16071607
EOF
1608-
test_must_fail git config --get section.key >actual 2>error &&
1608+
test_must_fail git config --get section.key 2>error &&
16091609
test_i18ngrep " line 3 " error
16101610
'
16111611

@@ -1615,17 +1615,17 @@ test_expect_success 'barf on incomplete section header' '
16151615
[section
16161616
key = value
16171617
EOF
1618-
test_must_fail git config --get section.key >actual 2>error &&
1618+
test_must_fail git config --get section.key 2>error &&
16191619
test_i18ngrep " line 2 " error
16201620
'
16211621

16221622
test_expect_success 'barf on incomplete string' '
16231623
cat >.git/config <<-\EOF &&
1624-
# broken section line
1624+
# broken value string
16251625
[section]
16261626
key = "value string
16271627
EOF
1628-
test_must_fail git config --get section.key >actual 2>error &&
1628+
test_must_fail git config --get section.key 2>error &&
16291629
test_i18ngrep " line 3 " error
16301630
'
16311631

t/t1450-fsck.sh

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -989,10 +989,7 @@ test_expect_success 'fsck error and recovery on invalid object type' '
989989
990990
garbage_blob=$(git hash-object --stdin -w -t garbage --literally </dev/null) &&
991991
992-
cat >err.expect <<-\EOF &&
993-
fatal: invalid object type
994-
EOF
995-
test_must_fail git fsck >out 2>err &&
992+
test_must_fail git fsck 2>err &&
996993
grep -e "^error" -e "^fatal" err >errors &&
997994
test_line_count = 1 errors &&
998995
grep "$garbage_blob: object is of unknown type '"'"'garbage'"'"':" err

t/t1502-rev-parse-parseopt.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -302,14 +302,14 @@ test_expect_success 'test --parseopt help output: "wrapped" options normal "or:"
302302
|EOF
303303
END_EXPECT
304304
305-
test_must_fail git rev-parse --parseopt -- -h >out <spec >actual &&
305+
test_must_fail git rev-parse --parseopt -- -h <spec >actual &&
306306
test_cmp expect actual
307307
'
308308

309309
test_expect_success 'test --parseopt invalid opt-spec' '
310310
test_write_lines x -- "=, x" >spec &&
311311
echo "fatal: missing opt-spec before option flags" >expect &&
312-
test_must_fail git rev-parse --parseopt -- >out <spec 2>err &&
312+
test_must_fail git rev-parse --parseopt -- <spec 2>err &&
313313
test_cmp expect err
314314
'
315315

@@ -339,7 +339,7 @@ test_expect_success 'test --parseopt help output: multi-line blurb after empty l
339339
|EOF
340340
END_EXPECT
341341
342-
test_must_fail git rev-parse --parseopt -- -h >out <spec >actual &&
342+
test_must_fail git rev-parse --parseopt -- -h <spec >actual &&
343343
test_cmp expect actual
344344
'
345345

t/t2019-checkout-ambiguous-ref.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ test_expect_success 'setup ambiguous refs' '
1616
'
1717

1818
test_expect_success 'checkout ambiguous ref succeeds' '
19-
git checkout ambiguity >stdout 2>stderr
19+
git checkout ambiguity 2>stderr
2020
'
2121

2222
test_expect_success 'checkout produces ambiguity warning' '
@@ -37,7 +37,7 @@ test_expect_success 'checkout reports switch to branch' '
3737
'
3838

3939
test_expect_success 'checkout vague ref succeeds' '
40-
git checkout vagueness >stdout 2>stderr &&
40+
git checkout vagueness 2>stderr &&
4141
test_set_prereq VAGUENESS_SUCCESS
4242
'
4343

0 commit comments

Comments
 (0)