From: Karthik Nayak Date: Mon, 20 Oct 2025 08:18:31 +0000 (+0200) Subject: t/pack-refs-tests: move the 'test_done' to callees X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c113f4ca4dbba5529af645f7d7837c7dae12b403;p=thirdparty%2Fgit.git t/pack-refs-tests: move the 'test_done' to callees In ac0bad0af4 (t0601: refactor tests to be shareable, 2025-09-19), we refactored 't/t0601-reffiles-pack-refs.sh' to move all of the tests to 't/pack-refs-tests.sh', which became a common test suite which was also used by 't/t1463-refs-optimize.sh'. This also moved the 'test_done' directive to 't/pack-refs-tests.sh'. Which inhibits additional tests from being added to either of the tests. Let's move the directive out to both the tests, so that we can add additional specific tests to them. Also the test flow logic shouldn't be part of tests which can be embedded in other test scripts. Signed-off-by: Karthik Nayak Signed-off-by: Junio C Hamano --- diff --git a/t/pack-refs-tests.sh b/t/pack-refs-tests.sh index 095823d915..81086c3690 100644 --- a/t/pack-refs-tests.sh +++ b/t/pack-refs-tests.sh @@ -459,5 +459,3 @@ test_expect_success 'pack-refs does not store invalid peeled tag value' ' test_grep ! "^\^" .git/packed-refs ) ' - -test_done diff --git a/t/t0601-reffiles-pack-refs.sh b/t/t0601-reffiles-pack-refs.sh index 12cf5d1dcb..3c706978ef 100755 --- a/t/t0601-reffiles-pack-refs.sh +++ b/t/t0601-reffiles-pack-refs.sh @@ -18,3 +18,5 @@ export GIT_TEST_DEFAULT_REF_FORMAT . ./test-lib.sh . "$TEST_DIRECTORY"/pack-refs-tests.sh + +test_done diff --git a/t/t1463-refs-optimize.sh b/t/t1463-refs-optimize.sh index c11c905d79..9afe3c1ed7 100755 --- a/t/t1463-refs-optimize.sh +++ b/t/t1463-refs-optimize.sh @@ -15,3 +15,5 @@ export GIT_TEST_DEFAULT_REF_FORMAT pack_refs='refs optimize' . "$TEST_DIRECTORY"/pack-refs-tests.sh + +test_done