blob: 8a308fbf7ef53b24fa1ad0cbfbe5a6c04ad75cbd [file] [log] [blame]
#!/bin/sh
#
# Copyright (c) 2007 Karl Hasselström
#
test_description='Make sure that we can use old StGIT repositories'
. ./test-lib.sh
for ver in 0.12 0.8; do
tar zxf ../t4000-upgrade/$ver.tar.gz
cd $ver
test_expect_success \
"v$ver: Check the list of applied and unapplied patches" '
[ "$(echo $(stg applied))" = "p0 p1 p2" ] &&
[ "$(echo $(stg unapplied))" = "p3 p4" ]
'
test_expect_success \
"v$ver: Make sure the 'description' file is no longer there" '
[ ! -e .git/patches/master/description ] &&
[ "$(echo $(git config branch.master.description))" = "cool branch" ]
'
test_expect_success \
"v$ver: Make sure the 'current' file is no longer there" '
[ ! -e .git/patches/master/current ]
'
test_expect_success \
"v$ver: Make sure the base ref is no longer there" '
! git show-ref --verify --quiet refs/bases/master
'
cd ..
done
test_done