summaryrefslogtreecommitdiff
path: root/t/t6022-merge-rename.sh
diff options
context:
space:
mode:
authorElijah Newren <newren@gmail.com>2011-08-12 05:20:25 (GMT)
committerJunio C Hamano <gitster@pobox.com>2011-08-14 21:19:40 (GMT)
commitf53d39778cf41cc93aa140bb41bb7d3a6590e179 (patch)
tree9f2759c063dba3f84c6642a41db735d08fb751d2 /t/t6022-merge-rename.sh
parent3f680ff0cf41c80b5c3a7ef4e7b417c0aa788dfb (diff)
downloadgit-f53d39778cf41cc93aa140bb41bb7d3a6590e179.zip
git-f53d39778cf41cc93aa140bb41bb7d3a6590e179.tar.gz
git-f53d39778cf41cc93aa140bb41bb7d3a6590e179.tar.bz2
merge-recursive: Fix spurious 'refusing to lose untracked file...' messages
Calling update_stages() before update_file() can sometimes result in git thinking the file being updated is untracked (whenever update_stages moves it to stage 3). Reverse the call order, and add a big comment to update_stages to hopefully prevent others from making the same mistake. Signed-off-by: Elijah Newren <newren@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t6022-merge-rename.sh')
-rwxr-xr-xt/t6022-merge-rename.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t6022-merge-rename.sh b/t/t6022-merge-rename.sh
index 0fd2b0a..8f75762 100755
--- a/t/t6022-merge-rename.sh
+++ b/t/t6022-merge-rename.sh
@@ -787,7 +787,7 @@ test_expect_success 'setup spurious "refusing to lose untracked" message' '
git commit -mC
'
-test_expect_failure 'no spurious "refusing to lose untracked" message' '
+test_expect_success '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