]> git.ipfire.org Git - thirdparty/git.git/commitdiff
t1302: don't create unused file
authorAndrei Rybak <rybak.a.v@gmail.com>
Sat, 18 Mar 2023 15:46:43 +0000 (16:46 +0100)
committerJunio C Hamano <gitster@pobox.com>
Mon, 20 Mar 2023 16:11:41 +0000 (09:11 -0700)
Test 'gitdir selection on unsupported repo' in t1302-repo-version.sh
writes output of a "git config" invocation to file "actual".  However,
the test doesn't have any assertions for the file.  The file was used by
this test until commit b9605bc4f2 (config: only read .git/config from
configured repos, 2016-09-12), before which "git config" was expected to
print the bogus value of "core.repositoryformatversion" to standard
output.

Don't redirect output of "git config" to file "actual" in test 'gitdir
selection on unsupported repo'.

Signed-off-by: Andrei Rybak <rybak.a.v@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t1302-repo-version.sh

index 70389fa2ebbfa47ad410ca5c30bb294b6cf0753f..179474fa651e159bf68714620ab4f1be2c259fe5 100755 (executable)
@@ -37,7 +37,7 @@ test_expect_success 'gitdir selection on normal repos' '
 
 test_expect_success 'gitdir selection on unsupported repo' '
        # Make sure it would stop at test2, not trash
-       test_expect_code 1 git -C test2 config core.repositoryformatversion >actual
+       test_expect_code 1 git -C test2 config core.repositoryformatversion
 '
 
 test_expect_success 'gitdir not required mode' '