Skip to content

Commit 43c94bb

Browse files
bk2204gitster
authored andcommitted
t1407: make hash size independent
Instead of hard-coding a 40-based constant, split the output of for-each-ref and for-each-reflog by field. Signed-off-by: brian m. carlson <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent b1484ca commit 43c94bb

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

t/t1407-worktree-ref-store.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ test_expect_success 'for_each_reflog()' '
5858
mkdir -p .git/worktrees/wt/logs/refs/bisect &&
5959
echo $ZERO_OID > .git/worktrees/wt/logs/refs/bisect/wt-random &&
6060
61-
$RWT for-each-reflog | cut -c 42- | sort >actual &&
61+
$RWT for-each-reflog | cut -d" " -f 2- | sort >actual &&
6262
cat >expected <<-\EOF &&
6363
HEAD 0x1
6464
PSEUDO-WT 0x0
@@ -68,7 +68,7 @@ test_expect_success 'for_each_reflog()' '
6868
EOF
6969
test_cmp expected actual &&
7070
71-
$RMAIN for-each-reflog | cut -c 42- | sort >actual &&
71+
$RMAIN for-each-reflog | cut -d" " -f 2- | sort >actual &&
7272
cat >expected <<-\EOF &&
7373
HEAD 0x1
7474
PSEUDO-MAIN 0x0

0 commit comments

Comments
 (0)