2008-02-03 07:47:22 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
test_description='properly cull all ancestors'
|
|
|
|
|
|
|
|
. ./test-lib.sh
|
|
|
|
|
|
|
|
commit () {
|
|
|
|
test_tick &&
|
|
|
|
echo $1 >file &&
|
|
|
|
git commit -a -m $1 &&
|
|
|
|
git tag $1
|
|
|
|
}
|
|
|
|
|
|
|
|
test_expect_success setup '
|
|
|
|
|
|
|
|
touch file &&
|
|
|
|
git add file &&
|
|
|
|
|
|
|
|
commit one &&
|
|
|
|
|
|
|
|
test_tick=$(($test_tick - 2400))
|
|
|
|
|
|
|
|
commit two &&
|
|
|
|
commit three &&
|
|
|
|
commit four &&
|
|
|
|
|
|
|
|
git log --pretty=oneline --abbrev-commit
|
|
|
|
'
|
|
|
|
|
2008-03-18 01:56:33 +00:00
|
|
|
test_expect_success 'one is ancestor of others and should not be shown' '
|
2008-02-03 07:47:22 +00:00
|
|
|
|
|
|
|
git rev-list one --not four >result &&
|
|
|
|
>expect &&
|
2008-03-12 21:36:36 +00:00
|
|
|
test_cmp expect result
|
2008-02-03 07:47:22 +00:00
|
|
|
|
|
|
|
'
|
|
|
|
|
|
|
|
test_done
|