Skip to content

Commit 734fde2

Browse files
andreas-schwabpeff
authored andcommitted
t6026-merge-attr: don't fail if sleep exits early
Commit 5babb5b ("t6026-merge-attr: clean up background process at end of test case") added a kill command to clean up after the test, but this can fail if the sleep command exits before the cleanup is executed. Ignore the error from the kill command. Signed-off-by: Andreas Schwab <[email protected]> Signed-off-by: Jeff King <[email protected]>
1 parent 5babb5b commit 734fde2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

t/t6026-merge-attr.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -187,7 +187,7 @@ test_expect_success 'custom merge does not lock index' '
187187
sleep 1 &
188188
echo $! >sleep.pid
189189
EOF
190-
test_when_finished "kill \$(cat sleep.pid)" &&
190+
test_when_finished "kill \$(cat sleep.pid) || :" &&
191191
192192
test_write_lines >.gitattributes \
193193
"* merge=ours" "text merge=sleep-one-second" &&

0 commit comments

Comments
 (0)