diff options
author | Junio C Hamano <gitster@pobox.com> | 2013-03-28 14:37:53 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2013-03-28 14:37:53 -0700 |
commit | 436b60ce7aac4cf8e496c57c9baae46094571b22 (patch) | |
tree | 7caa04a8f179fa651146ea2ab03fd5724ba5088d /t | |
parent | Merge branch 'jk/checkout-attribute-lookup' (diff) | |
parent | simplify-merges: drop merge from irrelevant side branch (diff) | |
download | tgif-436b60ce7aac4cf8e496c57c9baae46094571b22.tar.xz |
Merge branch 'jc/remove-treesame-parent-in-simplify-merges'
The --simplify-merges logic did not cull irrelevant parents from a
merge that is otherwise not interesting with respect to the paths
we are following.
This touches a fairly core part of the revision traversal
infrastructure; even though I think this change is correct, please
report immediately if you find any unintended side effect.
* jc/remove-treesame-parent-in-simplify-merges:
simplify-merges: drop merge from irrelevant side branch
Diffstat (limited to 't')
-rwxr-xr-x | t/t6012-rev-list-simplify.sh | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/t/t6012-rev-list-simplify.sh b/t/t6012-rev-list-simplify.sh index 839ad97b79..8e2ff13423 100755 --- a/t/t6012-rev-list-simplify.sh +++ b/t/t6012-rev-list-simplify.sh @@ -56,7 +56,23 @@ test_expect_success setup ' echo "Final change" >file && test_tick && git commit -a -m "Final change" && - note I + note I && + + git symbolic-ref HEAD refs/heads/unrelated && + git rm -f "*" && + echo "Unrelated branch" >side && + git add side && + test_tick && git commit -m "Side root" && + note J && + + git checkout master && + test_tick && git merge -m "Coolest" unrelated && + note K && + + echo "Immaterial" >elif && + git add elif && + test_tick && git commit -m "Last" && + note L ' FMT='tformat:%P %H | %s' @@ -79,10 +95,10 @@ check_result () { ' } -check_result 'I H G F E D C B A' --full-history -check_result 'I H E C B A' --full-history -- file -check_result 'I H E C B A' --full-history --topo-order -- file -check_result 'I H E C B A' --full-history --date-order -- file +check_result 'L K J I H G F E D C B A' --full-history +check_result 'K I H E C B A' --full-history -- file +check_result 'K I H E C B A' --full-history --topo-order -- file +check_result 'K I H E C B A' --full-history --date-order -- file check_result 'I E C B A' --simplify-merges -- file check_result 'I B A' -- file check_result 'I B A' --topo-order -- file |