summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 814f7d9)
raw | patch | inline | side by side (parent: 814f7d9)
author | Elijah Newren <newren@gmail.com> | |
Fri, 12 Aug 2011 05:20:24 +0000 (23:20 -0600) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Sun, 14 Aug 2011 21:19:39 +0000 (14:19 -0700) |
Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
t/t6022-merge-rename.sh | patch | blob | history |
index 74dcf20b88ac52ab18fa11c0a157626cf7a3afd8..0fd2b0a10e47e3b77a16600aadcdd828cf5ef601 100755 (executable)
--- a/t/t6022-merge-rename.sh
+++ b/t/t6022-merge-rename.sh
test_cmp expected renamed_file
'
+test_expect_success 'setup spurious "refusing to lose untracked" message' '
+ git rm -rf . &&
+ git clean -fdqx &&
+ rm -rf .git &&
+ git init &&
+
+ > irrelevant_file &&
+ printf "1\n2\n3\n4\n5\n6\n7\n8\n" >original_file &&
+ git add irrelevant_file original_file &&
+ git commit -mA &&
+
+ git checkout -b rename &&
+ git mv original_file renamed_file &&
+ git commit -mB &&
+
+ git checkout master &&
+ git rm original_file &&
+ git commit -mC
+'
+
+test_expect_failure 'no spurious "refusing to lose untracked" message' '
+ git checkout master^0 &&
+ test_must_fail git merge rename^0 2>errors.txt &&
+ ! grep "refusing to lose untracked file" errors.txt
+'
+
test_done