diff options
author | Adrian Likins <alikins@grimlock.devel.redhat.com> | 2008-01-29 17:51:31 -0500 |
---|---|---|
committer | Adrian Likins <alikins@grimlock.devel.redhat.com> | 2008-01-29 17:51:31 -0500 |
commit | 5dfe042f8b511e7e56157cd56fcc949c736308dc (patch) | |
tree | 198936f88a9d347fa19f0236bf6d71cd1af7b6a0 /test | |
parent | aa64577a30d8d11bcc89f15393886420c3c97348 (diff) | |
download | third_party-func-5dfe042f8b511e7e56157cd56fcc949c736308dc.tar.gz third_party-func-5dfe042f8b511e7e56157cd56fcc949c736308dc.tar.xz third_party-func-5dfe042f8b511e7e56157cd56fcc949c736308dc.zip |
add an optional config file "test-it.conf"
make running the unittests optional
remove "pound_on_threads" stuff cause it was stupid and slow
Diffstat (limited to 'test')
-rwxr-xr-x | test/test-it.sh | 54 |
1 files changed, 31 insertions, 23 deletions
diff --git a/test/test-it.sh b/test/test-it.sh index 6660739..974f6b3 100755 --- a/test/test-it.sh +++ b/test/test-it.sh @@ -31,6 +31,27 @@ INSTALL_VIA_RPMS=N # we are going to be deleting it from the normal spot? BACKUP_FUNC_PKI="N" +# do we want to run the unit tests as well +RUN_UNITTESTS="Y" +# you can put conf stuff in test-it.conf +# so you don't have to worry about checking in config stuff +if [ -f "test-it.conf" ] ; then + source test-it.conf +fi + + +show_config() +{ + echo "BUILD_PATH=$BUILD_PATH" + echo "RPM_PATH=$RPM_PATH" + echo "BUILD=$BUILD" + echo "BUILD_FROM_FRESH_CHECKOUT=$BUILD_FROM_FRESH_CHECKOUT" + echo "INSTALL_VIA_RPMS=$INSTALL_VIA_RPMS" + echo "BACKUP_FUNC_PKL=$BACKUP_FUNC_PKI" + echo "RUN_UNITTESTS=$RUN_UNITTESTS" + +} + rm -rf $RPM_PATH/rpms rm -rf $RPM_PATH/srpms rm -rf $RPM_PATH/tars @@ -186,27 +207,6 @@ sign_the_certmaster_certs() } -pound_on_the_threads() -{ - msg "Trying to poke at the threads a bit" - THREAD_COUNT=5 - for i in $MINION_CERTS - do - for Q in `seq 1 $THREAD_COUNT` - do - # background these so they run more or less in parallel to - # each minion - echo "test add $Q 6" for $i - func $i call test add "$Q" "6" & - done - done - - # this is kind of dumb and ugly, but it gives a change for all the - # connections to complete before we shut the server down - sleep 10 - -} - # just some random "poke at func and make sure it works stuff" test_funcd() { @@ -238,6 +238,13 @@ run_unittests() } + + +# start doing stuff + +show_config + + if [ "$BUILD" == "Y" ] ; then if [ "$BUILD_FROM_FRESH_CHECKOUT" == "Y" ] ; then check_out_code @@ -288,9 +295,10 @@ sign_the_certmaster_certs test_funcd -pound_on_the_threads -run_unittests +if [ "$RUN_UNITTEST" == "Y" ] ; then + run_unittests +fi run_async_test |