3 # Copyright (c) 2005 Junio C Hamano
6 test_description='Merge base computation.
16 export GIT_COMMITTER_EMAIL=git@comm.iter.xz
17 export GIT_COMMITTER_NAME='C O Mmiter'
18 export GIT_AUTHOR_NAME='A U Thor'
19 export GIT_AUTHOR_EMAIL=git@au.thor.xz
27 PARENTS="${PARENTS}-p $P "
29 GIT_COMMITTER_DATE="$(($M + $OFFSET)) $Z"
30 GIT_AUTHOR_DATE=$GIT_COMMITTER_DATE
31 export GIT_COMMITTER_DATE GIT_AUTHOR_DATE
32 commit=$(echo $NAME | git-commit-tree $T $PARENTS)
33 echo $commit >.git/refs/tags/$NAME
47 test_expect_success 'compute merge-base (single)' \
48 'MB=$(git-merge-base G H) &&
49 expr "$(git-name-rev "$MB")" : "[0-9a-f]* B"'
51 test_expect_success 'compute merge-base (all)' \
52 'MB=$(git-merge-base --all G H) &&
53 expr "$(git-name-rev "$MB")" : "[0-9a-f]* B"'
55 test_expect_success 'compute merge-base with show-branch' \
56 'MB=$(git-show-branch --merge-base G H) &&
57 expr "$(git-name-rev "$MB")" : "[0-9a-f]* B"'