diff options
| author | Junio C Hamano <gitster@pobox.com> | 2026-03-27 11:00:01 -0700 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2026-03-27 11:00:01 -0700 |
| commit | 828988bef368456e613a0e0bb5f1ba9580a6b341 (patch) | |
| tree | b73797b92169dd65ad60298d2f53ef97b903a6ba /t | |
| parent | 968e62c18794535f9b010d3075806f0950aa16bb (diff) | |
| parent | 57246b7c626c18bad5f7a36b9479dea58b73242d (diff) | |
| download | git-828988bef368456e613a0e0bb5f1ba9580a6b341.tar.xz | |
Merge branch 'mr/merge-file-object-id-worktree-fix'
merge-file --object-id used to trigger a BUG when run in a linked
worktree, which has been fixed.
* mr/merge-file-object-id-worktree-fix:
merge-file: fix BUG when --object-id is used in a worktree
Diffstat (limited to 't')
| -rwxr-xr-x | t/t6403-merge-file.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/t/t6403-merge-file.sh b/t/t6403-merge-file.sh index 4d6e748320..801284cf8f 100755 --- a/t/t6403-merge-file.sh +++ b/t/t6403-merge-file.sh @@ -542,6 +542,15 @@ test_expect_success '--object-id fails without repository' ' grep "not a git repository" err ' +test_expect_success 'run in a linked worktree with --object-id' ' + empty="$(test_oid empty_blob)" && + git worktree add work && + git -C work merge-file --object-id $empty $empty $empty >actual && + git worktree remove work && + git merge-file --object-id $empty $empty $empty >expected && + test_cmp actual expected +' + test_expect_success 'merging C files with "myers" diff algorithm creates some spurious conflicts' ' cat >expect.c <<-\EOF && int g(size_t u) |
