diff options
author | Elijah Newren <newren@gmail.com> | 2010-09-20 02:28:36 -0600 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2010-09-29 17:32:36 -0700 |
commit | df0b99f00458dd0d442b17d78dd4c171a89f7bb2 (patch) | |
tree | 0b31eed23a6b2f3fc208f33e1a68a4f820c124df /t/t6032-merge-large-rename.sh | |
parent | 7edba4c45c33ba1e17d88907c1601dc660a44522 (diff) | |
download | git-df0b99f00458dd0d442b17d78dd4c171a89f7bb2.tar.gz |
t6032: Add a test checking for excessive output from merge
Previous D/F fixes I submitted (5a2580d and ae74548) had caused merge to
become excessively spammy, which was fixed in 96ecac6 (merge-recursive:
Avoid excessive output for and reprocessing of renames 2010-08-20). Add a
new test to avoid repeating that mistake with my several upcoming changes.
Signed-off-by: Elijah Newren <newren@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t6032-merge-large-rename.sh')
-rwxr-xr-x | t/t6032-merge-large-rename.sh | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/t/t6032-merge-large-rename.sh b/t/t6032-merge-large-rename.sh index eac5ebac24..fdb6c25371 100755 --- a/t/t6032-merge-large-rename.sh +++ b/t/t6032-merge-large-rename.sh @@ -70,4 +70,34 @@ test_expect_success 'set merge.renamelimit to 5' ' test_rename 5 ok test_rename 6 fail +test_expect_success 'setup large simple rename' ' + git config --unset merge.renamelimit && + git config --unset diff.renamelimit && + + git reset --hard initial && + for i in $(count 200); do + make_text foo bar baz >$i + done && + git add . && + git commit -m create-files && + + git branch simple-change && + git checkout -b simple-rename && + + mkdir builtin && + git mv [0-9]* builtin/ && + git commit -m renamed && + + git checkout simple-change && + >unrelated-change && + git add unrelated-change && + git commit -m unrelated-change +' + +test_expect_success 'massive simple rename does not spam added files' ' + unset GIT_MERGE_VERBOSITY && + git merge --no-stat simple-rename | grep -v Removing >output && + test 5 -gt "$(wc -l < output)" +' + test_done |