Add index.lock test to t/t6026-merge-attr.sh

This test was added to verify the behaviour of merge
when a merge server is spawned.

Because file handles are inherited by child processes,
the index.lock is also inherited and - on win32 - can't
be released until the child has stopped.

Signed-off-by: Ben Wijen <ben@wijen.net>
This commit is contained in:
Ben Wijen
2016-05-26 08:57:26 +02:00
committed by Johannes Schindelin
parent 207577383b
commit ebb0d647db

View File

@@ -181,4 +181,19 @@ test_expect_success 'up-to-date merge without common ancestor' '
)
'
test_expect_success 'custom merge does not lock index' '
git reset --hard anchor &&
write_script sleep-one-second.sh <<-\EOF &&
sleep 1 &
EOF
printf "* merge=ours\ntext merge=sleep-one-second\n" >.gitattributes &&
git config merge.ours.driver "true" &&
git config merge.sleep-one-second.driver "./sleep-one-second.sh" &&
git merge master
'
test_done