diff options
author | Michael E Brown <michael_e_brown@dell.com> | 2007-12-03 10:44:13 -0600 |
---|---|---|
committer | Michael E Brown <michael_e_brown@dell.com> | 2007-12-03 10:44:13 -0600 |
commit | 1c06980dc2b7e5adc9e7a63f06c02e80d9fb624f (patch) | |
tree | ac5ac2bc9e7b1f96dd559a2e3e60079921f4e253 /docs/releasetests.sh | |
parent | e7b404406b6d825712d7882b8c8da61af896ea1a (diff) | |
download | mock-1c06980dc2b7e5adc9e7a63f06c02e80d9fb624f.tar.gz mock-1c06980dc2b7e5adc9e7a63f06c02e80d9fb624f.tar.xz mock-1c06980dc2b7e5adc9e7a63f06c02e80d9fb624f.zip |
update release tests to do more thorough testing.
Diffstat (limited to 'docs/releasetests.sh')
-rwxr-xr-x | docs/releasetests.sh | 55 |
1 files changed, 48 insertions, 7 deletions
diff --git a/docs/releasetests.sh b/docs/releasetests.sh index b4269de..3eac0f4 100755 --- a/docs/releasetests.sh +++ b/docs/releasetests.sh @@ -17,19 +17,60 @@ DIR=$(cd $(dirname $0); pwd) TOP_SRCTREE=$DIR/../ cd $TOP_SRCTREE -make distcheck ||: +make distclean ||: ./configure +make distcheck make srpm make src/daemontest +# +# most tests below will use this mock command line +# +testConfig=fedora-8-x86_64 +MOCKCMD="time sudo ./py/mock.py --resultdir=$TOP_SRCTREE/mock-unit-test --uniqueext=unittest -r $testConfig" +CHROOT=/var/lib/mock/$testConfig/root + +# +# pre-populate yum cache for the rest of the commands below +# +$MOCKCMD --installdeps mock-*.src.rpm + +# +# Test orphanskill feature +# +(pgrep daemontest && echo "Exiting because there is already a daemontest running." && exit 1) || : +$MOCKCMD --offline --init +cp src/daemontest $CHROOT/tmp +$MOCKCMD --offline --chroot -- /tmp/daemontest +(pgrep daemontest && echo "Daemontest FAILED. found a daemontest process running after exit." && exit 1) || : + +# +# Test offline build +# +$MOCKCMD --offline --rebuild mock-*.src.rpm + +# +# test init/clean +# +$MOCKCMD --offline --clean +$MOCKCMD --offline --init +$MOCKCMD --offline --install ccache +[ -e $CHROOT/usr/bin/ccache ] || (echo "init/clean test FAILED. ccache not found." && exit 1) + +# +# test old-style cmdline options +# +$MOCKCMD --offline clean +$MOCKCMD --offline init +$MOCKCMD --offline install ccache +[ -e $CHROOT/usr/bin/ccache ] || (echo "init/clean test FAILED. ccache not found." && exit 1) + +# +# Test build all configs we ship. +# sudo rm -rf $TOP_SRCTREE/mock-unit-test for i in $(ls etc/mock | grep .cfg | grep -v default | grep -v ppc); do time sudo ./py/mock.py --resultdir=$TOP_SRCTREE/mock-unit-test --uniqueext=unittest rebuild mock-*.src.rpm -r $(basename $i .cfg) done -(pgrep daemontest && echo "Exiting because there is already a daemontest running." && exit 1) || : -testConfig=fedora-8-x86_64 -sudo ./py/mock.py -r $testConfig --resultdir=$TOP_SRCTREE/mock-unit-test init -cp src/daemontest /var/lib/mock/$testConfig/root/tmp/ -sudo ./py/mock.py -r $testConfig --resultdir=$TOP_SRCTREE/mock-unit-test --no-clean -- chroot /tmp/daemontest -(pgrep daemontest && echo "Daemontest FAILED. found a daemontest process running after exit." && exit 1) || : + |