Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHan-Wen Nienhuys <hanwen@google.com>2021-08-02 19:53:32 +0300
committerJunio C Hamano <gitster@pobox.com>2021-08-02 23:17:21 +0300
commita50234b3be9d6ff75dfca9b0802e7cf97179ff11 (patch)
treeec9b5d06765b5307888618847afc8628cfc86f99 /t/t1405-main-ref-store.sh
parentace40eab9e8ee4d087b8ba7b603db4958e8ad28c (diff)
t1405: mark test for 'git pack-refs' as REFFILES
The tests verifies that "pack-refs" causes loose refs to be packed. As both loose and packed refs are concepts specific to the files backend, mark the test as REFFILES. Check the outcome of the pack-refs operation. This was apparently forgotten in the commit introducing this test: 16feb99d (Mar 26 2017, "t1405: some basic tests on main ref store"). Signed-off-by: Han-Wen Nienhuys <hanwen@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t1405-main-ref-store.sh')
-rwxr-xr-xt/t1405-main-ref-store.sh14
1 files changed, 10 insertions, 4 deletions
diff --git a/t/t1405-main-ref-store.sh b/t/t1405-main-ref-store.sh
index 92b0487324..49718b7ea7 100755
--- a/t/t1405-main-ref-store.sh
+++ b/t/t1405-main-ref-store.sh
@@ -9,12 +9,18 @@ export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
RUN="test-tool ref-store main"
-test_expect_success 'pack_refs(PACK_REFS_ALL | PACK_REFS_PRUNE)' '
- test_commit one &&
+
+test_expect_success 'setup' '
+ test_commit one
+'
+
+test_expect_success REFFILES 'pack_refs(PACK_REFS_ALL | PACK_REFS_PRUNE)' '
N=`find .git/refs -type f | wc -l` &&
test "$N" != 0 &&
- $RUN pack-refs 3 &&
- N=`find .git/refs -type f | wc -l`
+ ALL_OR_PRUNE_FLAG=3 &&
+ $RUN pack-refs ${ALL_OR_PRUNE_FLAG} &&
+ N=`find .git/refs -type f` &&
+ test -z "$N"
'
test_expect_success 'create_symref(FOO, refs/heads/main)' '